Package io.modelcontextprotocol.spec
Record Class McpSchema.ProgressNotification
java.lang.Object
java.lang.Record
io.modelcontextprotocol.spec.McpSchema.ProgressNotification
- Enclosing class:
- McpSchema
-
Constructor Summary
ConstructorsConstructorDescriptionProgressNotification(String progressToken, double progress, Double total) Creates an instance of aProgressNotificationrecord 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.doubleprogress()Returns the value of theprogressrecord component.Returns the value of theprogressTokenrecord component.final StringtoString()Returns a string representation of this record class.total()Returns the value of thetotalrecord component.
-
Constructor Details
-
ProgressNotification
Creates an instance of aProgressNotificationrecord class.- Parameters:
progressToken- the value for theprogressTokenrecord componentprogress- the value for theprogressrecord componenttotal- the value for thetotalrecord 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 '=='. -
progressToken
Returns the value of theprogressTokenrecord component.- Returns:
- the value of the
progressTokenrecord component
-
progress
public double progress()Returns the value of theprogressrecord component.- Returns:
- the value of the
progressrecord component
-
total
Returns the value of thetotalrecord component.- Returns:
- the value of the
totalrecord component
-