Package com.google.gxp.compiler.codegen

Examples of com.google.gxp.compiler.codegen.CodeGenerator


   * specified {@code OutputLanguage}.
   */
  void execute(AlertSink alertSink, AlertPolicy alertPolicy) {
    SourcePosition outputPosition = new SourcePosition(outputFileRef);
    alertSink.add(new ProgressAlert(outputPosition, "Generating"));
    CodeGenerator codeGenerator =
        codeGeneratorFactory.getCodeGenerator(language, compilationUnit);

    AlertCounter counter = new AlertCounter(alertSink, alertPolicy);

    StringBuilder sb = new StringBuilder();
    try {
      codeGenerator.generateCode(sb, counter);

      if (counter.getErrorCount() == 0) {
        Writer writer = outputFileRef.openWriter(Charsets.US_ASCII);
        try {
          writer.write(sb.toString());
View Full Code Here

TOP

Related Classes of com.google.gxp.compiler.codegen.CodeGenerator

Copyright © 2018 www.massapicom. 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.