Design of base components + Clock

* Code improvement
* Clock implementation
* Tests
* License headers
This would be unnecessary if the Cancellable is a parameter of the active state.