pub struct Cursor {
pub offset: u64,
}Expand description
Opaque pagination cursor carried on paginated tool requests / responses.
On the wire this serialises as a URL-safe base64 string; in Rust code
it is a typed offset. Construct directly (Cursor { offset: 100 }) or
receive via serde. The JSON representation is intentionally opaque to
clients.
Fields§
§offset: u64Zero-based row offset into the backend’s sorted item list.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Cursor
impl<'de> Deserialize<'de> for Cursor
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for Cursor
impl JsonSchema for Cursor
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§fn json_schema(_: &mut SchemaGenerator) -> Schema
fn json_schema(_: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
impl Copy for Cursor
impl Eq for Cursor
impl StructuralPartialEq for Cursor
Auto Trait Implementations§
impl Freeze for Cursor
impl RefUnwindSafe for Cursor
impl Send for Cursor
impl Sync for Cursor
impl Unpin for Cursor
impl UnsafeUnpin for Cursor
impl UnwindSafe for Cursor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more