[]
Serializable, Comparable<OperatorKind>, ConstableUse this enum with OperatorNode to represent arithmetic, comparison, reference, text-concatenation, and dynamic-array operators when building or inspecting parsed formulas.
FormulaSyntaxTree syntaxTree = new FormulaSyntaxTree();
OperatorNode rootNode = new OperatorNode(OperatorKind.Multiply);
syntaxTree.setRoot(rootNode);
Reference reference = new Reference();
reference.setRow(0);
reference.setColumn(0);
reference.setLastRow(7);
reference.setLastColumn(4);
reference.setIsRowRelative(false);
reference.setIsColumnRelative(true);
reference.setIsLastRowRelative(false);
reference.setIsLastColumnRelative(true);
rootNode.getChildren().add(new ReferenceNode(reference));
rootNode.getChildren().add(new NumberNode(9));
UnParseContext context = new UnParseContext();
context.setIsR1C1(true);
String formulaText = syntaxTree.toString(context);
Enum.EnumDesc<E extends Enum<E>>& operator.* operator.: operator.# operator., operator.static OperatorKindforValue(int value) intgetValue()static OperatorKindstatic OperatorKind[]values()The + operator has the primary purpose of adding two numbers. This operator is defined only for double operands, and it always narrows its operands to double.
Syntax:
expression1 + expression2 or +expression2
Parts:
expression1: Optional. Any numeric or string expression.
expression2: Required. Any numeric or string expression.
Returns the difference between two numeric expressions or the negative value of a numeric expression.
Syntax:
expression1 - expression2 or -expression2
Parts:
expression1: Optional. Any numeric or string expression.
expression2: Required. Any numeric or string expression.
* operator.Multiplies two numeric expressions and returns their product.
Syntax:
expression1 * expression2
Parts:
expression1: Required. Any numeric or string expression.
expression2: Required. Any numeric or string expression.
Divides two numbers and returns a floating-point result, including any remainder.
The QUOTIENT function returns the integer quotient and drops the remainder.
Syntax:
expression1 / expression2
Parts:
expression1: Required. Any numeric or string expression.
expression2: Required. Any numeric or string expression.
Raises a number to the power of another number, always as a double value.
Syntax:
number ^ exponent
Parts:
number: Required. Any numeric or string expression.
exponent: Required. Any numeric or string expression.
Divides a numeric expression by 100 and returns the result as a percentage value.
Syntax:
expression1%
Parts:
expression1: Required. Any numeric or string expression that can be converted to a number.
& operator.Concatenation operators join multiple strings into a single string. The & operator is defined only for string operands, and it always widens its operands to string.
Syntax:
expression1 & expression2
Parts:
expression1: Required. Any expression with a data type that widens to String.
expression2: Required. Any expression with a data type that widens to String.
: operator. The range operator returns a reference to all cells between the start and end reference cells, including both endpoints.
Syntax:
range1:range2
Parts:
range1: Required. Must be a range expression.
range2: Required. Must be a range expression.
, operator.The union operator combines two or more references into a single reference.
Syntax:
range1,range2
Parts:
range1: Required. Must be a range expression.
range2: Required. Must be a range expression.
The intersection operator gives a reference to the cells that are common to two range arguments.
Syntax:
range1 range2
Parts:
range1: Required. Must be a range expression.
range2: Required. Must be a range expression.
# operator. Refers to the entire spill range from the specified cell.
Syntax:
expression#
Parts:
expression: Required. Any cell reference expression.
@expression expression: Required. Any range or function call expression.The equality operator compares two expressions to determine whether or not they are equal.
Syntax:
expression1 = expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
The inequality operator compares two expressions to determine whether they are not equal.
Syntax:
expression1 <> expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
The less than operator compares two expressions to determine whether the left side is less than the right side.
Syntax:
expression1 < expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
The less than or equal operator compares two expressions to determine whether the left side is less than or equal to the right side.
Syntax:
expression1 <= expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
The greater than operator compares two expressions to determine whether the left side is greater than the right side.
Syntax:
expression1 > expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
The greater than or equal operator compares two expressions to determine whether the left side is greater than or equal to the right side.
Syntax:
expression1 >= expression2
Parts:
expression1: Required. Any expression.
expression2: Required. Any expression.
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum class has no constant with the specified nameNullPointerException - if the argument is nullvalue - The numeric value.