Inheritance: System.Attribute
Example #1
0
 /// Constructor
 public Factory(MemberInfo mi, FactoryAttribute fa)
 {
     _memberInfo       = mi;
     _factoryAttribute = fa;
     if (mi is MethodInfo)
     {
         ReturnType = (mi as MethodInfo).ReturnType;
     }
     else if (mi is PropertyInfo)
     {
         ReturnType = (mi as PropertyInfo).PropertyType;
     }
     else if (mi is ConstructorInfo)
     {
         ReturnType = (mi as ConstructorInfo).DeclaringType;
     }
     _log.DebugFormat("Found factory for {0} objects", ReturnType);
 }
Example #2
0
 /// Constructor
 public Factory(MemberInfo mi, FactoryAttribute fa)
 {
     _memberInfo = mi;
     _factoryAttribute = fa;
     if(mi is MethodInfo) {
         ReturnType = (mi as MethodInfo).ReturnType;
     }
     else if(mi is PropertyInfo) {
         ReturnType = (mi as PropertyInfo).PropertyType;
     }
     else if(mi is ConstructorInfo) {
         ReturnType = (mi as ConstructorInfo).DeclaringType;
     }
     _log.DebugFormat("Found factory for {0} objects", ReturnType);
 }