Struct twilight_http::request::channel::GetChannel
source · pub struct GetChannel<'a> { /* private fields */ }
Expand description
Get a channel by its ID.
Examples
Get channel 100
:
use twilight_http::Client;
use twilight_model::id::Id;
let client = Client::new("my token".to_owned());
let channel_id = Id::new(100);
let channel = client.channel(channel_id).await?;
Implementations
sourceimpl<'a> GetChannel<'a>
impl<'a> GetChannel<'a>
Trait Implementations
sourceimpl IntoFuture for GetChannel<'_>
impl IntoFuture for GetChannel<'_>
type Output = Result<Response<Channel>, Error>
type Output = Result<Response<Channel>, Error>
The output that the future will produce on completion.
type IntoFuture = ResponseFuture<Channel>
type IntoFuture = ResponseFuture<Channel>
Which kind of future are we turning this into?
sourcefn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
sourceimpl TryIntoRequest for GetChannel<'_>
impl TryIntoRequest for GetChannel<'_>
Auto Trait Implementations
impl<'a> !RefUnwindSafe for GetChannel<'a>
impl<'a> Send for GetChannel<'a>
impl<'a> Sync for GetChannel<'a>
impl<'a> Unpin for GetChannel<'a>
impl<'a> !UnwindSafe for GetChannel<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more