[−][src]Struct mqtt::topic_name::TopicNameRef
Reference to a topic name
Implementations
impl TopicNameRef[src]
pub fn new<S: AsRef<str> + ?Sized>(
topic_name: &S
) -> Result<&TopicNameRef, TopicNameError>[src]
topic_name: &S
) -> Result<&TopicNameRef, TopicNameError>
Creates a new topic name from string Return error if the string is not a valid topic name
pub unsafe fn new_unchecked<S: AsRef<str> + ?Sized>(
topic_name: &S
) -> &TopicNameRef[src]
topic_name: &S
) -> &TopicNameRef
Creates a new topic name from string without validation
Safety
Topic names' syntax is defined in MQTT specification. Creating a name from raw string may cause errors
pub fn is_server_specific(&self) -> bool[src]
Check if this topic name is only for server.
Topic names that beginning with a '$' character are reserved for servers
Trait Implementations
impl Debug for TopicNameRef[src]
impl Deref for TopicNameRef[src]
impl Eq for TopicNameRef[src]
impl Hash for TopicNameRef[src]
pub fn hash<__H: Hasher>(&self, state: &mut __H)[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
H: Hasher,