Examples of addComment()


Examples of net.percederberg.grammatica.code.csharp.CSharpConstructor.addComment()

        cls.addComment(new CSharpComment(TYPE_COMMENT));

        // Add constructor
        constr = new CSharpConstructor("TextReader input");
        cls.addConstructor(constr);
        constr.addComment(new CSharpComment(CONSTRUCTOR_COMMENT));
        constr.addInitializer("base(input, " +
                              !gen.getGrammar().getCaseSensitive() +
                              ")");
        constr.addCode("CreatePatterns();");
View Full Code Here

Examples of net.percederberg.grammatica.code.csharp.CSharpConstructor.addComment()

        enm.addComment(new CSharpComment(ENUM_COMMENT));

        // Add constructor
        constr = new CSharpConstructor("TextReader input");
        cls.addConstructor(constr);
        constr.addComment(new CSharpComment(CONSTRUCTOR1_COMMENT));
        constr.addInitializer("base(input)");
        constr.addCode("CreatePatterns();");

        // Add constructor
        constr = new CSharpConstructor("TextReader input, " +
View Full Code Here

Examples of net.percederberg.grammatica.code.csharp.CSharpConstructor.addComment()

        // Add constructor
        constr = new CSharpConstructor("TextReader input, " +
                                       analyzer.getClassName() + " analyzer");
        cls.addConstructor(constr);
        constr.addComment(new CSharpComment(CONSTRUCTOR2_COMMENT));
        constr.addInitializer("base(input, analyzer)");
        constr.addCode("CreatePatterns();");

        // Add tokenizer factory method
        method = new CSharpMethod(CSharpMethod.PROTECTED + CSharpMethod.OVERRIDE,
View Full Code Here

Examples of net.percederberg.grammatica.code.csharp.CSharpMethod.addComment()

        // Add tokenizer factory method
        method = new CSharpMethod(CSharpMethod.PROTECTED + CSharpMethod.OVERRIDE,
                                  "NewTokenizer",
                                  "TextReader input",
                                  "Tokenizer");
        method.addComment(new CSharpComment(FACTORY_COMMENT));
        method.addCode("return new " + tokenizer.getClassName() + "(input);");
        cls.addMethod(method);

        // Add init method
        cls.addMethod(initMethod);
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaConstructor.addComment()

        file.addComment(new JavaComment(JavaComment.BLOCK, str));

        // Add constructor
        constr = new JavaConstructor("Reader input");
        cls.addConstructor(constr);
        constr.addComment(new JavaComment(CONSTRUCTOR_COMMENT));
        constr.addThrows("ParserCreationException");
        constr.addCode("super(input, " +
                       !gen.getGrammar().getCaseSensitive() +
                       ");");
        constr.addCode("createPatterns();");
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaConstructor.addComment()

        file.addComment(new JavaComment(JavaComment.BLOCK, str));

        // Add constructor
        constr = new JavaConstructor("Reader in");
        cls.addConstructor(constr);
        constr.addComment(new JavaComment(CONSTRUCTOR1_COMMENT));
        constr.addThrows("ParserCreationException");
        constr.addCode("super(in);");
        constr.addCode("createPatterns();");

        // Add constructor
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaConstructor.addComment()

        // Add constructor
        constr = new JavaConstructor("Reader in, " + analyzer.getClassName() +
                                     " analyzer");
        cls.addConstructor(constr);
        constr.addComment(new JavaComment(CONSTRUCTOR2_COMMENT));
        constr.addThrows("ParserCreationException");
        constr.addCode("super(in, analyzer);");
        constr.addCode("createPatterns();");

        // Add tokenizer factory method
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaMethod.addComment()

        m = new JavaMethod(JavaMethod.PROTECTED,
                           "enter" + name,
                           type + " node",
                           "void");
        m.addComment(new JavaComment(ENTER_COMMENT));
        m.addThrows("ParseException");
        cls.addMethod(m);
    }

    /**
 
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaMethod.addComment()

        m = new JavaMethod(JavaMethod.PROTECTED,
                           "exit" + name,
                           type + " node",
                           "Node");
        m.addComment(new JavaComment(EXIT_COMMENT));
        m.addThrows("ParseException");
        m.addCode("return node;");
        cls.addMethod(m);
    }
View Full Code Here

Examples of net.percederberg.grammatica.code.java.JavaMethod.addComment()

        m = new JavaMethod(JavaMethod.PROTECTED,
                           "child" + name,
                           "Production node, Node child",
                           "void");
        m.addComment(new JavaComment(CHILD_COMMENT));
        m.addThrows("ParseException");
        m.addCode("node.addChild(child);");
        cls.addMethod(m);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.