Skip to main content

WebhookExt

Trait WebhookExt 

Source
pub trait WebhookExt: Sized {
    // Required methods
    fn from_token<'life0, 'life1, 'async_trait>(
        http: impl 'async_trait + AsRef<HttpClient> + Send,
        webhook_id: &'life0 str,
        token: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn from_url<'life0, 'async_trait>(
        http: impl 'async_trait + AsRef<HttpClient> + Send,
        url: &'life0 str,
    ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn delete<'life0, 'async_trait>(
        &'life0 self,
        http: impl 'async_trait + AsRef<HttpClient> + Send,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn edit(&self, http: impl AsRef<HttpClient>) -> EditWebhookBuilder;
    fn execute(&self, http: impl AsRef<HttpClient>) -> ExecuteWebhookBuilder;
}

Required Methods§

Source

fn from_token<'life0, 'life1, 'async_trait>( http: impl 'async_trait + AsRef<HttpClient> + Send, webhook_id: &'life0 str, token: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn from_url<'life0, 'async_trait>( http: impl 'async_trait + AsRef<HttpClient> + Send, url: &'life0 str, ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn delete<'life0, 'async_trait>( &'life0 self, http: impl 'async_trait + AsRef<HttpClient> + Send, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn edit(&self, http: impl AsRef<HttpClient>) -> EditWebhookBuilder

Source

fn execute(&self, http: impl AsRef<HttpClient>) -> ExecuteWebhookBuilder

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§