예제 #1
0
        public override ExpansionFunction CreateExpansionFunction(ExpansionProvider provider, string functionName)
        {
            ExpansionFunction function = null;

            if (functionName == "GetName")
            {
                ++classNameCounter;
                function = new PythonGetNameExpansionFunction(provider, classNameCounter);
            }
            return(function);
        }
예제 #2
0
        //Source source = GetSource(req.FullName);
        public override ExpansionFunction CreateExpansionFunction(ExpansionProvider provider,
                                                                  string functionName)
        {
            ExpansionFunction function = null;

            if (String.Compare(functionName, "GetClassName", true) == 0)
            {
                function = new MyGetClassNameExpansionFunction(provider);
            }
            else if (String.Compare(functionName, "EnumAccessType", true) == 0)
            {
                function = new MyEnumAccessTypeExpansionFunction(provider);
            }
            return(function);
        }
        public override ExpansionFunction CreateExpansionFunction(ExpansionProvider provider, string functionName)
        {
            ExpansionFunction function = null;

            if (functionName == "ClassName")
            {
                function = new ClassNameExpansionFunction(provider, ++classcounter);
            }
            else if (functionName == "GenerateSwitchCases")
            {
                function = new GenerateSwitchCasesExpansionFunction(provider);
            }
            else if (functionName == "SimpleTypeName")
            {
                function = new SimpleTypeNameExpansionFunction(provider);
            }
            else if (functionName == "InitProcType")
            {
                function = new InitProcTypeExpansionFunction(provider);
            }

            return(function);
        }