[−][src]Struct mqtt::topic_name::TopicName
Topic name
http://docs.oasis-open.org/mqtt/mqtt/v3.1.1/os/mqtt-v3.1.1-os.html#_Toc398718106
Implementations
impl TopicName[src]
pub fn new<S: Into<String>>(topic_name: S) -> Result<TopicName, TopicNameError>[src]
Creates a new topic name from string Return error if the string is not a valid topic name
pub unsafe fn new_unchecked(topic_name: String) -> TopicName[src]
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
Methods from Deref<Target = TopicNameRef>
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 Clone for TopicName[src]
impl Debug for TopicName[src]
impl Decodable for TopicName[src]
type Err = TopicNameError
type Cond = ()
pub fn decode_with<R: Read>(
reader: &mut R,
_rest: Option<()>
) -> Result<TopicName, TopicNameError>[src]
reader: &mut R,
_rest: Option<()>
) -> Result<TopicName, TopicNameError>
pub fn decode<R: Read>(reader: &mut R) -> Result<Self, Self::Err>[src]
impl Deref for TopicName[src]
type Target = TopicNameRef
The resulting type after dereferencing.
pub fn deref(&self) -> &TopicNameRef[src]
impl Encodable for TopicName[src]
type Err = TopicNameError
pub fn encode<W: Write>(&self, writer: &mut W) -> Result<(), TopicNameError>[src]
pub fn encoded_length(&self) -> u32[src]
impl Eq for TopicName[src]
impl From<TopicName> for String[src]
impl Hash for TopicName[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,
impl Into<TopicName> for TopicNameHeader[src]
impl Ord for TopicName[src]
pub fn cmp(&self, other: &TopicName) -> Ordering[src]
#[must_use]pub fn max(self, other: Self) -> Self1.21.0[src]
#[must_use]pub fn min(self, other: Self) -> Self1.21.0[src]
#[must_use]pub fn clamp(self, min: Self, max: Self) -> Self1.50.0[src]
impl PartialEq<TopicName> for TopicName[src]
impl PartialOrd<TopicName> for TopicName[src]
pub fn partial_cmp(&self, other: &TopicName) -> Option<Ordering>[src]
pub fn lt(&self, other: &TopicName) -> bool[src]
pub fn le(&self, other: &TopicName) -> bool[src]
pub fn gt(&self, other: &TopicName) -> bool[src]
pub fn ge(&self, other: &TopicName) -> bool[src]
impl StructuralEq for TopicName[src]
impl StructuralPartialEq for TopicName[src]
Auto Trait Implementations
impl RefUnwindSafe for TopicName[src]
impl Send for TopicName[src]
impl Sync for TopicName[src]
impl Unpin for TopicName[src]
impl UnwindSafe for TopicName[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>,