示例#1
0
        private void CreateProxyFuncs()
        {
            MethodInfo[] methods = Type.GetMethods(SEARCH_TYPE);
            for (int i = 0; i < methods.Length; i++)
            {
                var method            = methods[i];
                ZXParseAttribute attr = GetAttribute(method);

                // Add The Method
                if (attr != null)
                {
                    // If There Is No String, This Is Not A Proxy
                    if (attr.Key == null)
                    {
                        continue;
                    }
                    ZXPFunc v = new ZXPFunc(attr.Key, method);
                    Funcs.Add(v);
                    FuncsDict[v.Key] = v;
                }
                else
                {
                    ZXPFunc v = new ZXPFunc(method.Name, method);
                    Funcs.Add(v);
                    FuncsDict[v.Key] = v;
                }
            }
        }
示例#2
0
        private void CreateProxyFuncs()
        {
            MethodInfo[] methods = Type.GetMethods(SEARCH_TYPE);
            for(int i = 0; i < methods.Length; i++) {
                var method = methods[i];
                ZXParseAttribute attr = GetAttribute(method);

                // Add The Method
                if(attr != null) {
                    // If There Is No String, This Is Not A Proxy
                    if(attr.Key == null) continue;
                    ZXPFunc v = new ZXPFunc(attr.Key, method);
                    Funcs.Add(v);
                    FuncsDict[v.Key] = v;
                }
                else {
                    ZXPFunc v = new ZXPFunc(method.Name, method);
                    Funcs.Add(v);
                    FuncsDict[v.Key] = v;
                }
            }
        }