[]
        
(Showing Draft Content)

ArrayNode

Class ArrayNode


public class ArrayNode extends ConstNode
Represents an array literal in the syntax tree.
  • Constructor Details

    • ArrayNode

      public ArrayNode(Object[][] elements)
      Creates a new ArrayNode from array.
      Parameters:
      elements - Array elements. The value can't be null( Nothing).
  • Method Details

    • getElements

      public final Object[][] getElements()
      Gets the elements of this node as a two-dimensional array. The value can't be null.

      Supported types:

      double, String, boolean, CalcError.

      The following types will be normalized to double if you convert theArrayNode to string and then convert it back:

      byte, short, int, long, float.

      Floating-point types can't be NaN or infinity.

      Returns:
      A two-dimensional array containing the elements of this node.
    • setElements

      public final void setElements(Object[][] value)
      Array elements of this node. The value can't be null.

      Supported types:

      double, String, boolean, CalcError.

      The following types will be normalized to double if you convert theArrayNode to string and then convert it back:

      byte, short, int, long, float.

      Floating-point types can't be NaN or infinity.

      Parameters:
      value - A two-dimensional array containing the elements to be set for this node.