Build with Dip works

Trying to get the TinyIOC to work with dependency injection . Refactor
some code.