Example #1
0
 /// <summary>
 /// Derived Unregister Call Helper
 /// </summary>
 /// <param name="type">type for derived class</param>
 /// <param name="registerMethod">the method to call</param>
 /// <param name="registerAttribute">arguments</param>
 private static void CallDerivedUnRegisterMethod(Type type, MethodInfo registerMethod, UnRegisterFunctionAttribute registerAttribute)
 {
     if (registerAttribute.Value == RegisterMode.Replace)
     {
         registerMethod.Invoke(null, new object[] { type, RegisterCall.Replace });
     }
     else if (registerAttribute.Value == RegisterMode.CallBeforeAndAfter || registerAttribute.Value == RegisterMode.CallBefore)
     {
         registerMethod.Invoke(null, new object[] { type, RegisterCall.CallBefore });
     }
 }