Ejemplo n.º 1
0
 internal OneofAccessor(PropertyInfo caseProperty, MethodInfo clearMethod, OneofDescriptor descriptor)
 {
     if (!OneofAccessor.smethod_0(caseProperty))
     {
         throw OneofAccessor.smethod_1(Module.smethod_33 <string>(966859498u));
     }
     this.descriptor    = descriptor;
     this.caseDelegate  = ReflectionUtil.CreateFuncIMessageT <int>(caseProperty.GetGetMethod());
     this.descriptor    = descriptor;
     this.clearDelegate = ReflectionUtil.CreateActionIMessage(clearMethod);
 }
Ejemplo n.º 2
0
        public OneofAccessor(PropertyInfo caseProperty, MethodInfo clearMethod, OneofDescriptor descriptor)
        {
            if (!caseProperty.CanRead)
            {
                throw new ArgumentException("Cannot read from property");
            }
            this.descriptor = descriptor;
            caseDelegate    = ReflectionUtil.CreateFuncIMessageT <int>(caseProperty.GetGetMethod());

            this.descriptor = descriptor;
            clearDelegate   = ReflectionUtil.CreateActionIMessage(clearMethod);
        }