Class BoxForIndex

All Implemented Interfaces:
BoxVisitable

public class BoxForIndex extends BoxStatement
AST Node representing a for statement like: for(variable;expression;expression) body
  • Constructor Details

  • Method Details

    • getInitializer

      public BoxExpression getInitializer()
    • getCondition

      public BoxExpression getCondition()
    • getStep

      public BoxExpression getStep()
    • getBody

      public BoxStatement getBody()
    • setInitializer

      public void setInitializer(BoxExpression initializer)
    • setCondition

      public void setCondition(BoxExpression condition)
    • setStep

      public void setStep(BoxExpression step)
    • setBody

      public void setBody(BoxStatement body)
    • getLabel

      public String getLabel()
      Gets the label of the statement
      Returns:
      the label of the statement
    • setLabel

      public void setLabel(String label)
      Sets the label of the statement
      Parameters:
      label - the label of the statement
    • toMap

      public Map<String,Object> toMap()
      Overrides:
      toMap in class BoxNode
    • accept

      public void accept(VoidBoxVisitor v)
      Description copied from interface: BoxVisitable
      Accept method for visitor support.
      Parameters:
      v - the visitor implementation
    • accept

      public BoxNode accept(ReplacingBoxVisitor v)
      Description copied from interface: BoxVisitable
      Accept method for replacing visitor support. Each accept returns the node, or a replacement node.
      Parameters:
      v - the visitor implementation