Examples of toSourceString()


Examples of com.google.template.soy.soytree.RawTextNode.toSourceString()

    assertEquals(
        "  aaa bbb ccc {} ddd \neee <br>fffggg\nhhh }{  \u2222\uEEEE\u9EC4\u607A",
        rtn.getRawText());
    assertEquals(
        "  aaa bbb ccc {lb}{rb} ddd {\\n}eee <br>fffggg{\\n}hhh {rb}{lb}  \u2222\uEEEE\u9EC4\u607A",
        rtn.toSourceString());
  }


  public void testParseComments() throws Exception {
View Full Code Here

Examples of com.google.template.soy.soytree.SoyNode.toSourceString()

          if (combined.isErrorContext()) {
            throw SoyAutoescapeException.createWithNode(
                (node instanceof IfNode ?
                    "{if} command branch ends in a different context than preceding branches: " :
                    "{switch} command case ends in a different context than preceding cases: ") +
                    branch.toSourceString(),
                branch);
          }
          out = combined;
          if (branch instanceof IfElseNode || branch instanceof SwitchDefaultNode) {
            sawElseOrDefault = true;
View Full Code Here

Examples of com.google.template.soy.soytree.SwitchNode.toSourceString()

    assertEquals(
        "Bloh", ((RawTextNode) ((SwitchDefaultNode) sn.getChild(3)).getChild(0)).getRawText());

    assertEquals(
        "{switch $boo}{case 0}Blah{case $foo.goo}Bleh{case -1, 1, $moo}Bluh{default}Bloh{/switch}",
        sn.toSourceString());
  }


  public void testParseForeachStmt() throws Exception {
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.