Implemented IoC using StructureMap

Fixes #1