Struct egg_mode::direct::DMEntities
source · pub struct DMEntities {
pub hashtags: Vec<HashtagEntity>,
pub symbols: Vec<HashtagEntity>,
pub urls: Vec<UrlEntity>,
pub user_mentions: Vec<MentionEntity>,
}
Expand description
Container for URL, hashtag, and mention information associated with a direct message.
As far as entities are concerned, a DM can contain nearly everything a tweet can. The only
thing that isn’t present here is the “extended media” that would be on the tweet’s
extended_entities
field. A user can attach a single picture to a DM, but if that is present,
it will be available in the attachments
field of the original DirectMessage
struct and not
in the entities.
For all other fields, if the message contains no hashtags, financial symbols (“cashtags”), links, or mentions, those corresponding fields will be empty.
Fields§
Collection of hashtags parsed from the DM.
symbols: Vec<HashtagEntity>
Collection of financial symbols, or “cashtags”, parsed from the DM.
urls: Vec<UrlEntity>
Collection of URLs parsed from the DM.
user_mentions: Vec<MentionEntity>
Collection of user mentions parsed from the DM.