Enum minint::messages::ServerMsg

source ·
pub enum ServerMsg {
    Announce {
        name: String,
        id: i32,
        type: String,
        pubuid: Option<i32>,
        properties: BTreeMap<String, bool>,
    },
    Unannounce {
        name: String,
        id: i32,
    },
    Properties {
        name: String,
        ack: bool,
    },
}

Variants§

§

Announce

Topic Announcement Message

The server shall send this message for each of the following conditions:

  • To all clients subscribed to a matching prefix when a topic is created
  • To a client in response to an Publish Request Message (publish) from that client

Fields

§name: String

Topic name

§id: i32

Topic ID

The identifier that the server will use in MessagePack messages for this topic

§type: String

Data type

The data type for the topic (as a string)

§pubuid: Option<i32>

Publisher UID

If this message was sent in response to a publish message, the Publisher UID provided in that message. Otherwise absent.

§properties: BTreeMap<String, bool>

Properties

Topic Properties

§

Unannounce

Topic Removed Message

The server shall send this message when a previously announced (via a Topic Announcement Message ([Announce]) topic is deleted.

Fields

§name: String

Topic name

§id: i32

Topic ID

The identifier that the server was using for value updates

§

Properties

Properties Update Message

The server shall send this message when a previously announced (via a Topic Announcement Message ([Announce]) topic has its properties changed (via Set Properties Message ([SetProperties]).

Fields

§name: String

Topic name

§ack: bool

Acknowledgement

True if this message is in response to a setproperties message from the same client. Otherwise absent.

Trait Implementations§

source§

impl Debug for ServerMsg

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ServerMsg

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

source§

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