[]
An ArrayNode stores a two-dimensional array of constant values that can be used as a literal expression in the syntax tree. Array and element values cannot be null. Supported element types are double, String, boolean, and CalcError. Primitive numeric values such as byte, short, int, long, and float are accepted, but they are normalized to double if the node is converted to text and then parsed again. Floating-point values cannot be NaN or infinity.
The array must contain at least one element, and each nested array must use a zero-based lower bound.
FormulaSyntaxTree syntaxTree = FormulaSyntaxTree.Parse("OR(A1={1,3,5})");
FunctionNode functionNode = (FunctionNode) syntaxTree.getRoot();
OperatorNode operatorNode = (OperatorNode) functionNode.getChildren().get(0);
ArrayNode arrayNode = (ArrayNode) operatorNode.getChildren().get(1);
Object[][] elements = arrayNode.getElements();
Object firstValue = elements[0][0];
final Object[][]final voidsetElements(Object[][] value) getChildrenArrayNode from an array.The specified array defines the literal values stored by this node. The value cannot be null. Supported element types are double, String, boolean, and CalcError. Numeric values such as byte, short, int, long, and float are accepted, but they are normalized to double if the node is converted to text and then parsed again. Floating-point values cannot be NaN or infinity.
elements - The array elements. The value cannot be null (Nothing).IllegalArgumentException - if elements is null, is empty, contains an empty nested array, contains a null element, contains an unsupported element type, or contains NaN or infinite floating-point values.The returned value is a two-dimensional array and is never null. Supported element types are double, String, boolean, and CalcError. Numeric values such as byte, short, int, long, and float are accepted, but they are normalized to double if the ArrayNode is converted to text and then parsed again. Floating-point values cannot be NaN or infinity.
FormulaSyntaxTree syntaxTree = FormulaSyntaxTree.Parse("OR(A1={1,3,5})");
FunctionNode functionNode = (FunctionNode) syntaxTree.getRoot();
OperatorNode operatorNode = (OperatorNode) functionNode.getChildren().get(0);
ArrayNode arrayNode = (ArrayNode) operatorNode.getChildren().get(1);
Object[][] elements = arrayNode.getElements();
Object firstValue = elements[0][0];
The specified value must be a two-dimensional array and must not be null. Supported element types are double, String, boolean, and CalcError. Numeric values such as byte, short, int, long, and float are accepted, but they are normalized to double if the ArrayNode is converted to text and then parsed again. Floating-point values cannot be NaN or infinity.
ArrayNode node = new ArrayNode(new Object[][] {
{1.0, "East"},
{true, CalcError.Value}
});
node.setElements(new Object[][] {
{2.0, "West"}
});
Object firstValue = node.getElements()[0][0];
value - A two-dimensional array containing the elements of this node.