Struct carapax::types::CreateForumTopic
source · pub struct CreateForumTopic { /* private fields */ }
Expand description
Creates a topic in a forum supergroup chat.
The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights.
Implementations§
source§impl CreateForumTopic
impl CreateForumTopic
sourcepub fn new<A, B>(chat_id: A, name: B) -> CreateForumTopic
pub fn new<A, B>(chat_id: A, name: B) -> CreateForumTopic
Creates a new CreateForumTopic
.
§Arguments
chat_id
- Unique identifier of the target chat.name
- Topic name; 1 - 128 characters.
sourcepub fn with_icon_color(self, value: ForumTopicIconColor) -> CreateForumTopic
pub fn with_icon_color(self, value: ForumTopicIconColor) -> CreateForumTopic
sourcepub fn with_icon_custom_emoji_id<T>(self, value: T) -> CreateForumTopic
pub fn with_icon_custom_emoji_id<T>(self, value: T) -> CreateForumTopic
Sets a new icon custom emoji ID.
§Arguments
value
- Unique identifier of the custom emoji shown as the topic icon.
Use GetForumTopicIconStickers
to get all allowed custom emoji identifiers.
Trait Implementations§
source§impl Clone for CreateForumTopic
impl Clone for CreateForumTopic
source§fn clone(&self) -> CreateForumTopic
fn clone(&self) -> CreateForumTopic
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CreateForumTopic
impl Debug for CreateForumTopic
source§impl Method for CreateForumTopic
impl Method for CreateForumTopic
§type Response = ForumTopic
type Response = ForumTopic
The type representing a successful result in an API response.
source§fn into_payload(self) -> Payload
fn into_payload(self) -> Payload
Converts the method into a payload for an HTTP request.
source§impl Serialize for CreateForumTopic
impl Serialize for CreateForumTopic
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for CreateForumTopic
impl RefUnwindSafe for CreateForumTopic
impl Send for CreateForumTopic
impl Sync for CreateForumTopic
impl Unpin for CreateForumTopic
impl UnwindSafe for CreateForumTopic
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