[−][src]Struct ntex_amqp_codec::Message
Fields
message_format: Option<MessageFormat>
header: Option<Header>
delivery_annotations: Option<VecSymbolMap>
message_annotations: Option<VecSymbolMap>
properties: Option<Properties>
application_properties: Option<VecStringMap>
body: MessageBody
Implementations
impl Message
[src]
pub fn with_body(body: Bytes) -> Message
[src]
Create new message and set body
pub fn with_messages(messages: Vec<TransferBody>) -> Message
[src]
Create new message and set messages as body
pub fn header(&self) -> Option<&Header>
[src]
Header
pub fn set_header(&mut self, header: Header) -> &mut Self
[src]
Set message header
pub fn properties(&self) -> Option<&Properties>
[src]
Message properties
pub fn properties_mut(&mut self) -> &mut Properties
[src]
Mutable reference to properties
pub fn set_properties<F>(&mut self, f: F) -> &mut Self where
F: Fn(&mut Properties),
[src]
F: Fn(&mut Properties),
Add property
pub fn app_properties(&self) -> Option<&VecStringMap>
[src]
Get application property
pub fn app_property(&self, key: &str) -> Option<&Variant>
[src]
Get application property
pub fn set_app_property<K, V>(&mut self, key: K, value: V) -> &mut Self where
K: Into<Str>,
V: Into<Variant>,
[src]
K: Into<Str>,
V: Into<Variant>,
Add application property
pub fn message_annotation(&self, key: &str) -> Option<&Variant>
[src]
Get message annotation
pub fn add_message_annotation<K, V>(&mut self, key: K, value: V) -> &mut Self where
K: Into<Symbol>,
V: Into<Variant>,
[src]
K: Into<Symbol>,
V: Into<Variant>,
Add message annotation
pub fn delivery_annotations(&self) -> Option<&VecSymbolMap>
[src]
Delivery annotations
pub fn delivery_annotations_mut(&mut self) -> Option<&mut VecSymbolMap>
[src]
Mut reference to delivery annotations
pub fn update<F>(self, f: F) -> Self where
F: Fn(Self) -> Self,
[src]
F: Fn(Self) -> Self,
Call closure with message reference
pub fn if_some<T, F>(self, value: &Option<T>, f: F) -> Self where
F: Fn(Self, &T) -> Self,
[src]
F: Fn(Self, &T) -> Self,
Call closure if value is Some value
pub fn body(&self) -> &MessageBody
[src]
Message body
pub fn value(&self) -> Option<&Variant>
[src]
Message value
pub fn set_value<V: Into<Variant>>(&mut self, v: V) -> &mut Self
[src]
Set message body value
pub fn set_body<F>(&mut self, f: F) -> &mut Self where
F: FnOnce(&mut MessageBody),
[src]
F: FnOnce(&mut MessageBody),
Set message body
pub fn reply_message(&self) -> Message
[src]
Create new message and set correlation_id
property
Trait Implementations
impl Clone for Message
[src]
impl Debug for Message
[src]
impl Decode for Message
[src]
impl Default for Message
[src]
impl Encode for Message
[src]
impl From<Message> for TransferBody
[src]
pub fn from(original: Message) -> TransferBody
[src]
impl PartialEq<Message> for Message
[src]
impl StructuralPartialEq for Message
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Message
[src]
impl Send for Message
[src]
impl !Sync for Message
[src]
impl Unpin for Message
[src]
impl UnwindSafe for Message
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,