예제 #1
0
        public DynamicMethod(string name, Type returnType, Type[] parameterTypes, Type owner, bool skipVisibility)
        {
            StackCrawlMark stackMark = StackCrawlMark.LookForMyCaller;

            DynamicMethod.PerformSecurityCheck(owner, ref stackMark, skipVisibility);
            Init(name, MethodAttributes.Public | MethodAttributes.Static, CallingConventions.Standard, returnType, parameterTypes, owner, null, skipVisibility);
        }
예제 #2
0
        public DynamicMethod(string name, Type returnType, Type[] parameterTypes, Module m)
        {
            StackCrawlMark stackMark = StackCrawlMark.LookForMyCaller;

            DynamicMethod.PerformSecurityCheck(m, ref stackMark, false);
            Init(name, MethodAttributes.Public | MethodAttributes.Static, CallingConventions.Standard, returnType, parameterTypes, null, m, false);
        }
예제 #3
0
        public DynamicMethod(string name,
                             MethodAttributes attributes,
                             CallingConventions callingConvention,
                             Type returnType,
                             Type[] parameterTypes,
                             Module m,
                             bool skipVisibility)
        {
            StackCrawlMark stackMark = StackCrawlMark.LookForMyCaller;

            DynamicMethod.PerformSecurityCheck(m, ref stackMark, skipVisibility);
            Init(name, attributes, callingConvention, returnType, parameterTypes, null, m, skipVisibility);
        }