Ejemplo n.º 1
0
        public override void Setup()
        {
            base.Setup();

            classConstructor1Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyClass));
            classConstructor2Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyClass).GetConstructor(new[] { typeof(int) }));
            classConstructor3Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyClass).GetConstructor(new[] { typeof(int), typeof(string) }));
            classConstructor4Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyClass).GetConstructor(new[] { typeof(int), typeof(string), typeof(object) }));

            structConstructor1Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyStruct));
            structConstructor2Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyStruct).GetConstructor(new[] { typeof(int) }));
            structConstructor3Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyStruct).GetConstructor(new[] { typeof(int), typeof(string) }));
            structConstructor4Wrapper = ReflectionUtility.CreateConstructorWrapper(typeof(DummyStruct).GetConstructor(new[] { typeof(int), typeof(string), typeof(object) }));
        }
Ejemplo n.º 2
0
 public InjectableEmptyConstructor(Type concreteType) : base(emptyAttributeProvider)
 {
     wrapper = ReflectionUtility.CreateConstructorWrapper(concreteType);
 }