Package dev.tachyonmcp.core.protocol
Record Class ProtocolRequestMapper.PageRequest
java.lang.Object
java.lang.Record
dev.tachyonmcp.core.protocol.ProtocolRequestMapper.PageRequest
- Record Components:
limit- maximum number of items to returncursor- opaque continuation token from a prior page, ornullfor the first page
- Enclosing interface:
ProtocolRequestMapper
public static record ProtocolRequestMapper.PageRequest(int limit, @Nullable String cursor)
extends Record
A page request.
-
Constructor Summary
ConstructorsConstructorDescriptionPageRequest(int limit, @Nullable String cursor) Creates an instance of aPageRequestrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable Stringcursor()Returns the value of thecursorrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intlimit()Returns the value of thelimitrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
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 '=='. -
limit
public int limit()Returns the value of thelimitrecord component.- Returns:
- the value of the
limitrecord component
-
cursor
Returns the value of thecursorrecord component.- Returns:
- the value of the
cursorrecord component
-