pub struct SlackMessage {
pub workspace: String,
pub conversation: String,
pub conversation_label: String,
pub ts: String,
pub thread_ts: Option<String>,
pub user: Option<String>,
pub author: Option<String>,
pub text: String,
pub parent_user_id: Option<String>,
pub latest_reply: Option<String>,
pub edited: Option<String>,
pub files: Vec<SlackFile>,
}Expand description
One message as the pump sees it, after matching. Carries what delivery needs and nothing the wire happened to include.
Fields§
§workspace: String§conversation: String§conversation_label: StringConversation name for display; the DM partner’s id when unnamed.
Not Option, so a caller never has to invent a fallback.
ts: String§thread_ts: Option<String>None on a message with no thread at all. Equal to ts on a
thread’s parent, and the parent’s ts on a reply.
user: Option<String>The name to display for the author, resolved by the connector: the
handle the search path sends, a bot’s own name, or a users.info
lookup. None means no name is known, and user carries a raw id
that must never be shown as one.
text: String§parent_user_id: Option<String>Set on a reply, carrying the parent’s author. This, not thread_ts,
is what marks a reply: a parent carries thread_ts too.
latest_reply: Option<String>A parent’s newest reply ts. Absent on a message with no replies.
edited: Option<String>The ts of the message’s newest edit, absent on one never edited.
An edit keeps the message’s own ts, so this is what says the text
changed after it was sent - and what keeps a redelivered correction
distinct from a re-run of the delivery it corrects.
files: Vec<SlackFile>Files shared on the message. A file-share with no text is a real
message, and the ids are what slack__attachment fetches with.
Trait Implementations§
Source§impl Clone for SlackMessage
impl Clone for SlackMessage
Source§impl Debug for SlackMessage
impl Debug for SlackMessage
impl Eq for SlackMessage
Source§impl PartialEq for SlackMessage
impl PartialEq for SlackMessage
impl StructuralPartialEq for SlackMessage
Auto Trait Implementations§
impl Freeze for SlackMessage
impl RefUnwindSafe for SlackMessage
impl Send for SlackMessage
impl Sync for SlackMessage
impl Unpin for SlackMessage
impl UnsafeUnpin for SlackMessage
impl UnwindSafe for SlackMessage
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.