pub struct Page<T> {
pub href: String,
pub limit: usize,
pub next: Option<String>,
pub offset: usize,
pub previous: Option<String>,
pub total: usize,
pub items: Vec<T>,
}Expand description
A paginated response containing a list of items.
Use the next and previous URLs or the pagination helper functions
to navigate through results.
Fields§
§href: StringA link to the Web API endpoint returning the full result of the request.
limit: usizeThe maximum number of items in the response (as set in the query or by default).
next: Option<String>URL to the next page of items
offset: usizeThe offset of the items returned (as set in the query or by default).
previous: Option<String>URL to the previous page of items.
total: usizeThe total number of items available to return.
items: Vec<T>Trait Implementations§
Source§impl<'de, T> Deserialize<'de> for Page<T>where
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de> for Page<T>where
T: Deserialize<'de>,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl<T: Eq> Eq for Page<T>
impl<T> StructuralPartialEq for Page<T>
Auto Trait Implementations§
impl<T> Freeze for Page<T>
impl<T> RefUnwindSafe for Page<T>where
T: RefUnwindSafe,
impl<T> Send for Page<T>where
T: Send,
impl<T> Sync for Page<T>where
T: Sync,
impl<T> Unpin for Page<T>where
T: Unpin,
impl<T> UnwindSafe for Page<T>where
T: UnwindSafe,
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