Package com.google.transconsole.common.messages

Examples of com.google.transconsole.common.messages.Message


    }

    Expression getResult() {
      if (!invalid) {
        try {
          Message message = tcMessageBuilder.createMessage();
          ExtractedMessage emsg =
              new ExtractedMessage(msg, msg.getSchema(), msg.getName(), message, parameters);
          outsideMessageVisitor.addMessages(emsg);
          return emsg;
        } catch (InvalidMessageException imx) {
View Full Code Here


      @Override
      public Void visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        formatLine("// MSG %s=%s",
                   tcMessage.getId(),
                   CharEscapers.javaStringUnicodeEscaper().escape(
                       tcMessage.getOriginal().replace("\n", " ")));

        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

      @Override
      public String visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(String.format("/* \"%s\" */ ",
                                CharEscapers.javaStringUnicodeEscaper().escape(
                                    tcMessage.getOriginal()
                                      .replace("\n", " ")
                                      .replace("\\*/", "*/"))));
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

      @Override
      public Void visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        formatLine("// MSG %s=%s",
                   tcMessage.getId(),
                   CharEscapers.javaStringUnicodeEscaper().escape(
                       tcMessage.getOriginal().replace("\n", " ")));

        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

      @Override
      public String visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(String.format("/* \"%s\" */ ",
                                CharEscapers.javaStringUnicodeEscaper().escape(
                                    tcMessage.getOriginal()
                                      .replace("\n", " ")
                                      .replace("\\*/", "*/"))));
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

      @Override
      public Void visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        formatLine("// MSG %s=%s",
                   tcMessage.getId(),
                   CharEscapers.javaStringUnicodeEscaper().escape(
                       tcMessage.getOriginal().replace("\n", " ")));

        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

      @Override
      public String visitExtractedMessage(ExtractedMessage msg) {
        if (runtimeMessageSource == null) {
          alertSink.add(new NoMessageSourceError(msg));
        }
        Message tcMessage = msg.getTcMessage();
        StringBuilder sb = new StringBuilder("GxpTemplate.getMessage(GXP$MESSAGE_SOURCE, ");
        sb.append("gxp_context.getLocale(), ");
        sb.append(String.format("/* \"%s\" */ ",
                                CharEscapers.javaStringUnicodeEscaper().escape(
                                    tcMessage.getOriginal()
                                      .replace("\n", " ")
                                      .replace("\\*/", "*/"))));
        sb.append(tcMessage.getId());
        sb.append("L");
        for (Expression param : msg.getParameters()) {
          sb.append(", ");
          sb.append(getEscapedString(param));
        }
View Full Code Here

TOP

Related Classes of com.google.transconsole.common.messages.Message

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.