Exemple #1
0
 /// <summary>
 /// Requires T2 having parameterless constructor
 /// </summary>
 public static void Register <T, T2>(this CompositionContainer container) where T2 : T, new()
 {
     container.RegisterFunc(() => new T2());
     container.RegisterFunc <T>(() => container.Resolve <T2>());
 }