Guest User

Untitled

a guest
Jan 21st, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. public interface IA {}
  2. public interface IB : IA {}
  3. internal class C : IB {}
  4.  
  5. Container.RegisterType<IB, C>();
  6.  
  7. Container.RegisterType<IA, C>();
  8.  
  9. Container.RegisterType<IA, IB>();
  10.  
  11. Container.RegisterType<IA>(new InjectionFactory(x=>x.Resolve<IB>()));
Add Comment
Please, Sign In to add comment