pub struct AMPCtx {
pub previous_sender: String,
pub id: u64,
/* private fields */
}
Fields§
§previous_sender: String
§id: u64
Implementations§
Source§impl AMPCtx
impl AMPCtx
pub fn new( origin: impl Into<String>, previous_sender: impl Into<String>, id: u64, origin_username: Option<AndrAddr>, ) -> AMPCtx
Sourcepub fn get_origin(&self) -> String
pub fn get_origin(&self) -> String
Gets the original sender of a message
Sourcepub fn get_previous_sender(&self) -> String
pub fn get_previous_sender(&self) -> String
Gets the previous sender of a message
Trait Implementations§
Source§impl<'de> Deserialize<'de> for AMPCtx
impl<'de> Deserialize<'de> for AMPCtx
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 JsonSchema for AMPCtx
impl JsonSchema for AMPCtx
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref
keyword. Read moreimpl StructuralPartialEq for AMPCtx
Auto Trait Implementations§
impl Freeze for AMPCtx
impl RefUnwindSafe for AMPCtx
impl Send for AMPCtx
impl Sync for AMPCtx
impl Unpin for AMPCtx
impl UnwindSafe for AMPCtx
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