Package com.tnsai.spi
Record Class CognitiveModel.Intention
java.lang.Object
java.lang.Record
com.tnsai.spi.CognitiveModel.Intention
- Enclosing interface:
CognitiveModel
public static record CognitiveModel.Intention(String id, String goalId, String planDescription, CognitiveModel.IntentionStatus status, List<String> steps, int currentStep)
extends Record
Represents an intention/plan in the cognitive model.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of thecurrentSteprecord component.final booleanIndicates whether some other object is "equal to" this one.static CognitiveModel.IntentiongoalId()Returns the value of thegoalIdrecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.Returns the value of theplanDescriptionrecord component.status()Returns the value of thestatusrecord component.steps()Returns the value of thestepsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Intention
public Intention(String id, String goalId, String planDescription, CognitiveModel.IntentionStatus status, List<String> steps, int currentStep) Creates an instance of aIntentionrecord class.- Parameters:
id- the value for theidrecord componentgoalId- the value for thegoalIdrecord componentplanDescription- the value for theplanDescriptionrecord componentstatus- the value for thestatusrecord componentsteps- the value for thestepsrecord componentcurrentStep- the value for thecurrentSteprecord component
-
-
Method Details
-
forGoal
-
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 '=='. -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
goalId
Returns the value of thegoalIdrecord component.- Returns:
- the value of the
goalIdrecord component
-
planDescription
Returns the value of theplanDescriptionrecord component.- Returns:
- the value of the
planDescriptionrecord component
-
status
Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
steps
Returns the value of thestepsrecord component.- Returns:
- the value of the
stepsrecord component
-
currentStep
public int currentStep()Returns the value of thecurrentSteprecord component.- Returns:
- the value of the
currentSteprecord component
-