code_junkie

IoC, Where do you put the container?

Nov 11th, 2011
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.18 KB | None | 0 0
  1. IServiceLocator container = ContainerFactory.GetContainer();
  2. while( keepLooping )
  3. {
  4. IExample example = container.GetInstance<IExample>();
  5. keepLooping = example.DoWork();
  6. }
Add Comment
Please, Sign In to add comment