Struct tgbot::types::TextEntities
source · pub struct TextEntities { /* private fields */ }
Expand description
Represents a collection of text entities.
Implementations§
source§impl TextEntities
impl TextEntities
sourcepub fn push(&mut self, value: TextEntity)
pub fn push(&mut self, value: TextEntity)
sourcepub fn serialize(&self) -> Result<String, TextEntityError>
pub fn serialize(&self) -> Result<String, TextEntityError>
Serializes text entities into a JSON string.
Trait Implementations§
source§impl Clone for TextEntities
impl Clone for TextEntities
source§fn clone(&self) -> TextEntities
fn clone(&self) -> TextEntities
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 TextEntities
impl Debug for TextEntities
source§impl<'de> Deserialize<'de> for TextEntities
impl<'de> Deserialize<'de> for TextEntities
source§fn 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
source§impl From<TextEntities> for Vec<TextEntity>
impl From<TextEntities> for Vec<TextEntity>
source§fn from(entities: TextEntities) -> Self
fn from(entities: TextEntities) -> Self
Converts to this type from the input type.
source§impl FromIterator<TextEntity> for TextEntities
impl FromIterator<TextEntity> for TextEntities
source§fn from_iter<T: IntoIterator<Item = TextEntity>>(iter: T) -> Self
fn from_iter<T: IntoIterator<Item = TextEntity>>(iter: T) -> Self
Creates a value from an iterator. Read more
source§impl Index<usize> for TextEntities
impl Index<usize> for TextEntities
source§impl IndexMut<usize> for TextEntities
impl IndexMut<usize> for TextEntities
source§impl<'a> IntoIterator for &'a TextEntities
impl<'a> IntoIterator for &'a TextEntities
source§impl<'a> IntoIterator for &'a mut TextEntities
impl<'a> IntoIterator for &'a mut TextEntities
source§impl IntoIterator for TextEntities
impl IntoIterator for TextEntities
§type Item = TextEntity
type Item = TextEntity
The type of the elements being iterated over.
§type IntoIter = IntoIter<<TextEntities as IntoIterator>::Item>
type IntoIter = IntoIter<<TextEntities as IntoIterator>::Item>
Which kind of iterator are we turning this into?
source§impl PartialEq for TextEntities
impl PartialEq for TextEntities
source§fn eq(&self, other: &TextEntities) -> bool
fn eq(&self, other: &TextEntities) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for TextEntities
impl PartialOrd for TextEntities
source§fn partial_cmp(&self, other: &TextEntities) -> Option<Ordering>
fn partial_cmp(&self, other: &TextEntities) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for TextEntities
impl Serialize for TextEntities
source§impl TryFrom<Vec<RawTextEntity>> for TextEntities
impl TryFrom<Vec<RawTextEntity>> for TextEntities
impl StructuralPartialEq for TextEntities
Auto Trait Implementations§
impl Freeze for TextEntities
impl RefUnwindSafe for TextEntities
impl Send for TextEntities
impl Sync for TextEntities
impl Unpin for TextEntities
impl UnwindSafe for TextEntities
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