Record Class ExpressionNode.Operator
java.lang.Object
java.lang.Record
org.cyclops.integrateddynamics.api.evaluate.expression.tree.ExpressionNode.Operator
- Record Components:
operator- The operator.children- The children, one for each operator input.
- All Implemented Interfaces:
ExpressionNode
- Enclosing interface:
ExpressionNode
public static record ExpressionNode.Operator(IOperator operator, List<ExpressionNode> children)
extends Record
implements ExpressionNode
An operator applied to child nodes.
-
Nested Class Summary
Nested classes/interfaces inherited from interface ExpressionNode
ExpressionNode.Const, ExpressionNode.Empty, ExpressionNode.Operator, ExpressionNode.Param, ExpressionNode.Ref -
Field Summary
Fields inherited from interface ExpressionNode
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionOperator(IOperator operator, List<ExpressionNode> children) Creates an instance of aOperatorrecord class. -
Method Summary
Modifier and TypeMethodDescriptionchildren()Returns the value of thechildrenrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static ExpressionNode.Operatoroperator()Returns the value of theoperatorrecord component.final StringtoString()Returns a string representation of this record class.withChild(int index, ExpressionNode child)
-
Constructor Details
-
Method Details
-
ofEmpty
- Parameters:
operator- An operator.- Returns:
- A node for the given operator with all children empty.
-
withChild
- Parameters:
index- A child index.child- The new child.- Returns:
- A copy of this node with the given child replaced.
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
operator
-
children
-