Package com.google.template.soy.soytree.SoyNode

Examples of com.google.template.soy.soytree.SoyNode.BlockNode.replaceChild()


        return// don't replace this node
      }
    }

    // Replace this node with a RawTextNode.
    parent.replaceChild(node, new RawTextNode(nodeIdGen.genId(), rawText));
    madeReplacement = true;
  }


  // -----------------------------------------------------------------------------------------------
View Full Code Here


    } catch (RenderException pe) {
      return// cannot prerender for some other reason not checked above
    }

    // Replace this node with a RawTextNode.
    parent.replaceChild(node, new RawTextNode(nodeIdGen.genId(), prerenderOutputSb.toString()));
  }


  @Override protected void visitIfNode(IfNode node) {
View Full Code Here

        return// don't replace this node
      }
    }

    // Replace this node with a RawTextNode.
    parent.replaceChild(node, new RawTextNode(nodeIdGen.genId(), rawText));
    madeReplacement = true;
  }


  // -----------------------------------------------------------------------------------------------
View Full Code Here

    GoogMsgRefNode googMsgRefNode =
        new GoogMsgRefNode(nodeIdGen.genId(), googMsgNode.getRenderedGoogMsgVarName());

    BlockNode parent = msgNode.getParent();
    int msgNodeIndex = parent.getChildIndex(msgNode);
    parent.replaceChild(msgNodeIndex, googMsgNode);
    parent.addChild(msgNodeIndex + 1, googMsgRefNode);
  }

}
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.