pub struct SearchHandler<'octo> { /* private fields */ }
Expand description
Handler for the search API.
Created with Octocrab::search
.
Implementations§
source§impl<'octo> SearchHandler<'octo>
impl<'octo> SearchHandler<'octo>
sourcepub fn repositories<'query>(
self,
query: &'query (impl AsRef<str> + ?Sized),
) -> QueryHandler<'octo, 'query, Repository>
pub fn repositories<'query>( self, query: &'query (impl AsRef<str> + ?Sized), ) -> QueryHandler<'octo, 'query, Repository>
Searches for all the repositories matching the search query.
let page = octocrab::instance()
.search()
.repositories("tetris language:rust")
.sort("stars")
.order("desc")
.send()
.await?;
sourcepub fn commits<'query>(
self,
query: &'query (impl AsRef<str> + ?Sized),
) -> QueryHandler<'octo, 'query, Commit>
pub fn commits<'query>( self, query: &'query (impl AsRef<str> + ?Sized), ) -> QueryHandler<'octo, 'query, Commit>
Searches for all the commits matching the search query.
let page = octocrab::instance()
.search()
.commits("hello world repo:XAMPPRocky/octocrab")
.sort("author-date")
.order("desc")
.send()
.await?;
sourcepub fn users<'query>(
self,
query: &'query (impl AsRef<str> + ?Sized),
) -> QueryHandler<'octo, 'query, Author>
pub fn users<'query>( self, query: &'query (impl AsRef<str> + ?Sized), ) -> QueryHandler<'octo, 'query, Author>
Searches for all users matching the search query.
let page = octocrab::instance()
.search()
.users("bors type:user")
.sort("followers")
.order("desc")
.send()
.await?;
sourcepub fn issues_and_pull_requests<'query>(
self,
query: &'query (impl AsRef<str> + ?Sized),
) -> QueryHandler<'octo, 'query, Issue>
pub fn issues_and_pull_requests<'query>( self, query: &'query (impl AsRef<str> + ?Sized), ) -> QueryHandler<'octo, 'query, Issue>
Searches for all the issues matching the search query.
let page = octocrab::instance()
.search()
.issues_and_pull_requests("GitHub Octocrab in:readme user:ferris")
.sort("comments")
.order("asc")
.send()
.await?;
sourcepub fn code<'query>(
self,
query: &'query (impl AsRef<str> + ?Sized),
) -> QueryHandler<'octo, 'query, Code>
pub fn code<'query>( self, query: &'query (impl AsRef<str> + ?Sized), ) -> QueryHandler<'octo, 'query, Code>
Searches for all code matching the search query.
let page = octocrab::instance()
.search()
.code("println! language:rust repo:rust-lang/rust")
.sort("indexed")
.order("asc")
.send()
.await?;
Auto Trait Implementations§
impl<'octo> Freeze for SearchHandler<'octo>
impl<'octo> !RefUnwindSafe for SearchHandler<'octo>
impl<'octo> Send for SearchHandler<'octo>
impl<'octo> Sync for SearchHandler<'octo>
impl<'octo> Unpin for SearchHandler<'octo>
impl<'octo> !UnwindSafe for SearchHandler<'octo>
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more