Package com.tnsai.feedback
Record Class FeedbackCollector.ToolOutcome
java.lang.Object
java.lang.Record
com.tnsai.feedback.FeedbackCollector.ToolOutcome
- Record Components:
toolName- the tool that was executedsuccess- whether the execution succeededlatencyMs- execution time in millisecondserror- error message if failed, null if success
- Enclosing interface:
FeedbackCollector
public static record FeedbackCollector.ToolOutcome(String toolName, boolean success, long latencyMs, String error)
extends Record
Immutable record of a tool execution outcome.
-
Constructor Summary
ConstructorsConstructorDescriptionToolOutcome(String toolName, boolean success, long latencyMs, String error) Creates an instance of aToolOutcomerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.error()Returns the value of theerrorrecord component.final inthashCode()Returns a hash code value for this object.longReturns the value of thelatencyMsrecord component.booleansuccess()Returns the value of thesuccessrecord component.toolName()Returns the value of thetoolNamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
success
-
failure
-
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 '=='. -
toolName
Returns the value of thetoolNamerecord component.- Returns:
- the value of the
toolNamerecord component
-
success
public boolean success()Returns the value of thesuccessrecord component.- Returns:
- the value of the
successrecord component
-
latencyMs
public long latencyMs()Returns the value of thelatencyMsrecord component.- Returns:
- the value of the
latencyMsrecord component
-
error
Returns the value of theerrorrecord component.- Returns:
- the value of the
errorrecord component
-