Package com.tnsai.session.consolidation
Record Class ConsolidationResult
java.lang.Object
java.lang.Record
com.tnsai.session.consolidation.ConsolidationResult
public record ConsolidationResult(String sessionId, String summary, List<ExtractedKnowledge> extractedKnowledge, int originalMessageCount, int consolidatedMessageCount, Duration duration)
extends Record
Result of a memory consolidation operation.
-
Constructor Summary
ConstructorsConstructorDescriptionConsolidationResult(String sessionId, String summary, List<ExtractedKnowledge> extractedKnowledge, int originalMessageCount, int consolidatedMessageCount, Duration duration) Creates an instance of aConsolidationResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of theconsolidatedMessageCountrecord component.duration()Returns the value of thedurationrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theextractedKnowledgerecord component.final inthashCode()Returns a hash code value for this object.booleanintintReturns the value of theoriginalMessageCountrecord component.Returns the value of thesessionIdrecord component.summary()Returns the value of thesummaryrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ConsolidationResult
public ConsolidationResult(String sessionId, String summary, List<ExtractedKnowledge> extractedKnowledge, int originalMessageCount, int consolidatedMessageCount, Duration duration) Creates an instance of aConsolidationResultrecord class.- Parameters:
sessionId- the value for thesessionIdrecord componentsummary- the value for thesummaryrecord componentextractedKnowledge- the value for theextractedKnowledgerecord componentoriginalMessageCount- the value for theoriginalMessageCountrecord componentconsolidatedMessageCount- the value for theconsolidatedMessageCountrecord componentduration- the value for thedurationrecord component
-
-
Method Details
-
hasKnowledge
public boolean hasKnowledge() -
knowledgeCount
public int knowledgeCount() -
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 '=='. -
sessionId
Returns the value of thesessionIdrecord component.- Returns:
- the value of the
sessionIdrecord component
-
summary
Returns the value of thesummaryrecord component.- Returns:
- the value of the
summaryrecord component
-
extractedKnowledge
Returns the value of theextractedKnowledgerecord component.- Returns:
- the value of the
extractedKnowledgerecord component
-
originalMessageCount
public int originalMessageCount()Returns the value of theoriginalMessageCountrecord component.- Returns:
- the value of the
originalMessageCountrecord component
-
consolidatedMessageCount
public int consolidatedMessageCount()Returns the value of theconsolidatedMessageCountrecord component.- Returns:
- the value of the
consolidatedMessageCountrecord component
-
duration
Returns the value of thedurationrecord component.- Returns:
- the value of the
durationrecord component
-