pub struct Ctx<T> { /* private fields */ }Implementations§
source§impl Ctx<Message>
impl Ctx<Message>
pub async fn send_message(&self, message: impl Into<String>) -> Result<()>
sourcepub async fn send_message_rnd(
&self,
message: impl Into<String>,
random_id: String
) -> Result<()>
pub async fn send_message_rnd( &self, message: impl Into<String>, random_id: String ) -> Result<()>
Send message using random id
pub async fn get_members( &self, offset: Option<u16>, count: Option<u16>, extended: bool ) -> Result<Members>
pub async fn keyboard<T: Serialize, N: NdArray<T>>( &self, message: impl Into<String>, one_time: bool, inline: bool, buttons: N ) -> Result<()>
source§impl Ctx<Update>
impl Ctx<Update>
pub async fn send_message( &self, message: impl Into<String>, peer_id: i32 ) -> Result<()>
pub async fn keyboard_callback<'de, T: Serialize, A: DeserializeOwned + PartialEq + Serialize>( &self, callback: T, _payload: A ) -> Result<Option<ButtonPressCallback<A>>>
Trait Implementations§
source§impl<S> FromUpdate<S> for Ctx<Update>
impl<S> FromUpdate<S> for Ctx<Update>
async fn from_update( update: Update, _state: &S, request: Arc<RequestBuilder> ) -> Result<Self, ()>
Auto Trait Implementations§
impl<T> Freeze for Ctx<T>where
T: Freeze,
impl<T> !RefUnwindSafe for Ctx<T>
impl<T> Send for Ctx<T>where
T: Send,
impl<T> Sync for Ctx<T>where
T: Sync,
impl<T> Unpin for Ctx<T>where
T: Unpin,
impl<T> !UnwindSafe for Ctx<T>
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