Struct telegram_types::bot::methods::DeleteMessage
source · pub struct DeleteMessage<'a> {
pub chat_id: ChatTarget<'a>,
pub message_id: MessageId,
}
Expand description
Use this method to delete a message, including service messages, with the following limitations:
- A message can only be deleted if it was sent less than 48 hours ago.
- Bots can delete outgoing messages in groups and supergroups.
- Bots granted can_post_messages permissions can delete outgoing messages in channels.
- If the bot is an administrator of a group, it can delete any message there.
- If the bot has can_delete_messages permission in a supergroup or a channel, it can delete any message there.
Returns True on success.
Fields
chat_id: ChatTarget<'a>
message_id: MessageId
Trait Implementations
sourceimpl<'a> Clone for DeleteMessage<'a>
impl<'a> Clone for DeleteMessage<'a>
sourcefn clone(&self) -> DeleteMessage<'a>
fn clone(&self) -> DeleteMessage<'a>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl<'a> Debug for DeleteMessage<'a>
impl<'a> Debug for DeleteMessage<'a>
sourceimpl<'de, 'a> Deserialize<'de> for DeleteMessage<'a>
impl<'de, 'a> Deserialize<'de> for DeleteMessage<'a>
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<'a> Method for DeleteMessage<'a>
impl<'a> Method for DeleteMessage<'a>
sourceimpl<'a> PartialEq<DeleteMessage<'a>> for DeleteMessage<'a>
impl<'a> PartialEq<DeleteMessage<'a>> for DeleteMessage<'a>
sourcefn eq(&self, other: &DeleteMessage<'a>) -> bool
fn eq(&self, other: &DeleteMessage<'a>) -> bool
sourceimpl<'a> Serialize for DeleteMessage<'a>
impl<'a> Serialize for DeleteMessage<'a>
impl<'a> Eq for DeleteMessage<'a>
impl<'a> StructuralEq for DeleteMessage<'a>
impl<'a> StructuralPartialEq for DeleteMessage<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for DeleteMessage<'a>
impl<'a> Send for DeleteMessage<'a>
impl<'a> Sync for DeleteMessage<'a>
impl<'a> Unpin for DeleteMessage<'a>
impl<'a> UnwindSafe for DeleteMessage<'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