pub struct SearchLabelsParams<'req> { /* private fields */ }Expand description
Query parameters for the Search labels endpoint.
Implementations§
Source§impl<'req> SearchLabelsParams<'req>
impl<'req> SearchLabelsParams<'req>
pub fn new() -> Self
Sourcepub fn repository_id(self, repository_id: i32) -> Self
pub fn repository_id(self, repository_id: i32) -> Self
The id of the repository.
Sourcepub fn q(self, q: &'req str) -> Self
pub fn q(self, q: &'req str) -> Self
The search keywords. This endpoint does not accept qualifiers in the query. To learn more about the format of the query, see Constructing a search query.
Sourcepub fn sort(self, sort: &'req str) -> Self
pub fn sort(self, sort: &'req str) -> Self
Sorts the results of your query by when the label was created or updated. Default: best match
Sourcepub fn order(self, order: &'req str) -> Self
pub fn order(self, order: &'req str) -> Self
Determines whether the first search result returned is the highest number of matches (desc) or lowest number of matches (asc). This parameter is ignored unless you provide sort.
Sourcepub fn per_page(self, per_page: u16) -> Self
pub fn per_page(self, per_page: u16) -> Self
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Sourcepub fn page(self, page: u16) -> Self
pub fn page(self, page: u16) -> Self
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Trait Implementations§
Source§impl<'req> Default for SearchLabelsParams<'req>
impl<'req> Default for SearchLabelsParams<'req>
Source§fn default() -> SearchLabelsParams<'req>
fn default() -> SearchLabelsParams<'req>
Returns the “default value” for a type. Read more
Source§impl<'enc> From<&'enc PerPage> for SearchLabelsParams<'enc>
impl<'enc> From<&'enc PerPage> for SearchLabelsParams<'enc>
Auto Trait Implementations§
impl<'req> Freeze for SearchLabelsParams<'req>
impl<'req> RefUnwindSafe for SearchLabelsParams<'req>
impl<'req> Send for SearchLabelsParams<'req>
impl<'req> Sync for SearchLabelsParams<'req>
impl<'req> Unpin for SearchLabelsParams<'req>
impl<'req> UnwindSafe for SearchLabelsParams<'req>
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