Add runtime functionality 

This PR adds some runtime functionality. It is best explained in the docs: https://github.com/johnstevenson/composer/blob/runtime-feature/doc/xx-runtime.md

I am not sure if this should be included in the core, or made available as a separate package.