Class Node.Nodes

  • Enclosing class:
    Node

    public static class Node.Nodes
    extends java.lang.Object
    An ordered list of Node, used to represent the body of an element, or a jsp page of jsp document.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add​(Node n)
      Appends a node to the list
      Node getNode​(int index)
      Returns the node at the given index.
      Node.Root getRoot()
      Returns the root node of this collection.
      boolean isGeneratedInBuffer()
      Returns whether the generated content is buffered.
      void remove​(Node n)
      Removes the given node from the list.
      void setGeneratedInBuffer​(boolean g)
      Sets whether the generated content is buffered.
      int size()
      Returns the number of nodes in this collection.
      void visit​(Node.Visitor v)
      Visit the nodes in the list with the supplied visitor
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • add

        public void add​(Node n)
        Appends a node to the list
        Parameters:
        n - The node to add
      • remove

        public void remove​(Node n)
        Removes the given node from the list.
        Parameters:
        n - The node to be removed
      • visit

        public void visit​(Node.Visitor v)
                   throws JasperException
        Visit the nodes in the list with the supplied visitor
        Parameters:
        v - The visitor used
        Throws:
        JasperException - if an error occurs while visiting a node
      • size

        public int size()
        Returns the number of nodes in this collection.
        Returns:
        The number of nodes
      • getNode

        public Node getNode​(int index)
        Returns the node at the given index.
        Parameters:
        index - The index of the node to retrieve
        Returns:
        The node at the given index, or null if out of bounds
      • getRoot

        public Node.Root getRoot()
        Returns the root node of this collection.
        Returns:
        The root node, or null if not set
      • isGeneratedInBuffer

        public boolean isGeneratedInBuffer()
        Returns whether the generated content is buffered.
        Returns:
        true if content is generated in a buffer
      • setGeneratedInBuffer

        public void setGeneratedInBuffer​(boolean g)
        Sets whether the generated content is buffered.
        Parameters:
        g - true if content is generated in a buffer