Package org.jruby.ast

Class AliasNode

java.lang.Object
org.jruby.ast.Node
org.jruby.ast.AliasNode

public class AliasNode extends Node
Represents an alias statement (alias newName oldName).
  • Constructor Details

    • AliasNode

      public AliasNode(int line, Node newName, Node oldName)
  • Method Details

    • getNodeType

      public NodeType getNodeType()
      Specified by:
      getNodeType in class Node
      Returns:
      the nodeId
    • accept

      public <T> T accept(NodeVisitor<T> iVisitor)
      Accept for the visitor pattern.
      Specified by:
      accept in class Node
      Parameters:
      iVisitor - the visitor
    • getNewName

      public Node getNewName()
      Gets the newName.
      Returns:
      the newName as in the alias statement : alias newName oldName
    • getOldName

      public Node getOldName()
      Gets the oldName.
      Returns:
      the oldName as in the alias statement : alias newName oldName
    • childNodes

      public List<Node> childNodes()
      Specified by:
      childNodes in class Node