[][src]Struct zbus::MessageHeader

pub struct MessageHeader<'m> { /* fields omitted */ }

The message header, containing all the metadata about the message.

This includes both the MessagePrimaryHeader and MessageFields.

Implementations

impl<'m> MessageHeader<'m>[src]

pub fn new(primary: MessagePrimaryHeader, fields: MessageFields<'m>) -> Self[src]

Create a new MessageHeader instance.

pub fn primary(&self) -> &MessagePrimaryHeader[src]

Get a reference to the primary header.

pub fn primary_mut(&mut self) -> &mut MessagePrimaryHeader[src]

Get a mutable reference to the primary header.

pub fn into_primary(self) -> MessagePrimaryHeader[src]

Get the primary header, consuming self.

pub fn fields<'s>(&'s self) -> &'s MessageFields<'m>[src]

Get a reference to the message fields.

pub fn fields_mut<'s>(&'s mut self) -> &'s mut MessageFields<'m>[src]

Get a mutable reference to the message fields.

pub fn into_fields(self) -> MessageFields<'m>[src]

Get the message fields, consuming self.

pub fn message_type(&self) -> Result<MessageType, MessageError>[src]

The message type

pub fn path<'s>(&'s self) -> Result<Option<&ObjectPath<'m>>, MessageError>[src]

The object to send a call to, or the object a signal is emitted from.

pub fn interface<'s>(&'s self) -> Result<Option<&'s str>, MessageError>[src]

The interface to invoke a method call on, or that a signal is emitted from.

pub fn member<'s>(&'s self) -> Result<Option<&'s str>, MessageError>[src]

The member, either the method name or signal name.

pub fn error_name<'s>(&'s self) -> Result<Option<&'s str>, MessageError>[src]

The name of the error that occurred, for errors.

pub fn reply_serial(&self) -> Result<Option<u32>, MessageError>[src]

The serial number of the message this message is a reply to.

pub fn destination<'s>(&'s self) -> Result<Option<&'s str>, MessageError>[src]

The name of the connection this message is intended for.

pub fn sender<'s>(&'s self) -> Result<Option<&'s str>, MessageError>[src]

Unique name of the sending connection.

pub fn signature(&self) -> Result<Option<&Signature<'m>>, MessageError>[src]

The signature of the message body.

pub fn unix_fds(&self) -> Result<Option<u32>, MessageError>[src]

The number of Unix file descriptors that accompany the message.

Trait Implementations

impl<'m> Debug for MessageHeader<'m>[src]

impl<'de: 'm, 'm> Deserialize<'de> for MessageHeader<'m>[src]

impl<'m> Serialize for MessageHeader<'m>[src]

impl<'m> Type for MessageHeader<'m>[src]

Auto Trait Implementations

impl<'m> RefUnwindSafe for MessageHeader<'m>[src]

impl<'m> Send for MessageHeader<'m>[src]

impl<'m> Sync for MessageHeader<'m>[src]

impl<'m> Unpin for MessageHeader<'m>[src]

impl<'m> UnwindSafe for MessageHeader<'m>[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.