Struct rule34::PostListQueryBuilder
source · pub struct PostListQueryBuilder<'a> {
pub tags: Option<&'a str>,
pub pid: Option<u64>,
pub id: Option<NonZeroU64>,
pub limit: Option<u16>,
/* private fields */
}
Expand description
A builder for post list api queries
Fields§
The tags.
pid: Option<u64>
The page #
Starts at 0.
id: Option<NonZeroU64>
The post id.
limit: Option<u16>
The limit.
Implementations§
source§impl<'a> PostListQueryBuilder<'a>
impl<'a> PostListQueryBuilder<'a>
sourcepub fn new(client: &'a Client) -> Self
pub fn new(client: &'a Client) -> Self
Make a new PostListQueryBuilder
.
Set the tags to list for.
Querys are based on “tags”. Tags are seperated by spaces, while words are seperated by underscores. Characters are automatically url-encoded.
sourcepub fn id(&mut self, id: Option<NonZeroU64>) -> &mut Self
pub fn id(&mut self, id: Option<NonZeroU64>) -> &mut Self
Set the post id
sourcepub fn limit(&mut self, limit: Option<u16>) -> &mut Self
pub fn limit(&mut self, limit: Option<u16>) -> &mut Self
Set the post limit.
This has a hard upper limit of 1000
.
Trait Implementations§
source§impl<'a> Clone for PostListQueryBuilder<'a>
impl<'a> Clone for PostListQueryBuilder<'a>
source§fn clone(&self) -> PostListQueryBuilder<'a>
fn clone(&self) -> PostListQueryBuilder<'a>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'a> Debug for PostListQueryBuilder<'a>
impl<'a> Debug for PostListQueryBuilder<'a>
impl<'a> Copy for PostListQueryBuilder<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for PostListQueryBuilder<'a>
impl<'a> Send for PostListQueryBuilder<'a>
impl<'a> Sync for PostListQueryBuilder<'a>
impl<'a> Unpin for PostListQueryBuilder<'a>
impl<'a> !UnwindSafe for PostListQueryBuilder<'a>
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