Package org.qaddict.evaluation
Record Class ExpectationNode
java.lang.Object
java.lang.Record
org.qaddict.evaluation.ExpectationNode
- All Implemented Interfaces:
EvaluationNode
public record ExpectationNode(boolean result, Object expectation, EvaluationNode child)
extends Record
implements EvaluationNode
-
Constructor Summary
ConstructorsConstructorDescriptionExpectationNode(boolean result, Object expectation, EvaluationNode child) Creates an instance of aExpectationNoderecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of theexpectationrecord component.final inthashCode()Returns a hash code value for this object.child()Returns the value of thechildrecord component.booleanresult()Returns the value of theresultrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ExpectationNode
Creates an instance of aExpectationNoderecord class.- Parameters:
result- the value for theresultrecord componentexpectation- the value for theexpectationrecord componentchild- the value for thechildrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
result
public boolean result()Returns the value of theresultrecord component.- Specified by:
resultin interfaceEvaluationNode- Returns:
- the value of the
resultrecord component
-
expectation
Returns the value of theexpectationrecord component.- Returns:
- the value of the
expectationrecord component
-
child
Returns the value of thechildrecord component.- Returns:
- the value of the
childrecord component
-