Record Class Expression
java.lang.Object
java.lang.Record
org.cyclops.integrateddynamics.api.evaluate.expression.tree.Expression
- Record Components:
root- The root node.parameters- The parameters.
An expression: a tree of nodes with an ordered list of parameters.
An expression without parameters evaluates to the value of its root,
an expression with parameters evaluates to an operator.
-
Constructor Summary
ConstructorsConstructorDescriptionExpression(ExpressionNode root) Expression(ExpressionNode root, List<ExpressionParameter> parameters) Creates an instance of aExpressionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theparametersrecord component.root()Returns the value of therootrecord component.final StringtoString()Returns a string representation of this record class.withParameters(List<ExpressionParameter> parameters) withRoot(ExpressionNode root)
-
Constructor Details
-
Expression
Creates an instance of aExpressionrecord class.- Parameters:
root- the value for therootrecord componentparameters- the value for theparametersrecord component
-
Expression
-
-
Method Details
-
withRoot
-
withParameters
-
hasParameters
public boolean hasParameters() -
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). -
root
-
parameters
Returns the value of theparametersrecord component.- Returns:
- the value of the
parametersrecord component
-