Enum serenity::model::ReactionType
[−]
[src]
pub enum ReactionType { Custom { id: EmojiId, name: String, }, Unicode(String), }
The type of a Reaction
sent.
Variants
Custom
Fields
id: EmojiId | The Id of the custom |
name: String | The name of the custom emoji. This is primarily used for decoration and distinguishing the emoji client-side. |
Unicode(String)
A reaction with a twemoji.
Methods
impl ReactionType
[src]
fn as_data(&self) -> String
Creates a data-esque display of the type. This is not very useful for displaying, as the primary client can not render it, but can be useful for debugging.
Note: This is mainly for use internally. There is otherwise most likely little use for it.
Trait Implementations
impl Clone for ReactionType
[src]
fn clone(&self) -> ReactionType
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for ReactionType
[src]
impl From<Emoji> for ReactionType
[src]
fn from(emoji: Emoji) -> ReactionType
Performs the conversion.
impl From<String> for ReactionType
[src]
fn from(unicode: String) -> ReactionType
Performs the conversion.
impl Display for ReactionType
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the reaction type, displaying the associated emoji in a way that clients can understand.
If the type is a custom emoji, then refer to the documentation for emoji's formatter on how this is displayed. Otherwise, if the type is a unicode, then the inner unicode is displayed.