[−][src]Struct async_coap::option::OptionNumber
Type representing a CoAP option number.
Methods
impl OptionNumber
[src]
pub const IF_MATCH: OptionNumber
[src]
IF_MATCH option.
pub const URI_HOST: OptionNumber
[src]
URI_HOST option.
pub const ETAG: OptionNumber
[src]
ETAG option.
pub const IF_NONE_MATCH: OptionNumber
[src]
IF_NONE_MATCH option.
pub const OBSERVE: OptionNumber
[src]
OBSERVE option.
pub const URI_PORT: OptionNumber
[src]
URI_PORT option.
pub const LOCATION_PATH: OptionNumber
[src]
LOCATION_PATH option.
pub const OSCORE: OptionNumber
[src]
OSCORE option.
pub const URI_PATH: OptionNumber
[src]
URI_PATH option.
pub const CONTENT_FORMAT: OptionNumber
[src]
CONTENT_FORMAT option.
pub const MAX_AGE: OptionNumber
[src]
MAX_AGE option.
pub const URI_QUERY: OptionNumber
[src]
URI_QUERY option.
pub const ACCEPT: OptionNumber
[src]
ACCEPT option.
pub const LOCATION_QUERY: OptionNumber
[src]
LOCATION_QUERY option.
pub const BLOCK2: OptionNumber
[src]
BLOCK2 option.
pub const BLOCK1: OptionNumber
[src]
BLOCK1 option.
pub const SIZE2: OptionNumber
[src]
SIZE2 option.
pub const PROXY_URI: OptionNumber
[src]
PROXY_URI option.
pub const PROXY_SCHEME: OptionNumber
[src]
PROXY_SCHEME option.
pub const SIZE1: OptionNumber
[src]
SIZE1 option.
pub const NO_RESPONSE: OptionNumber
[src]
NO_RESPONSE option.
pub fn is_critical(self) -> bool
[src]
Returns true if this option number is critical, false if it is optional.
pub fn is_un_safe(self) -> bool
[src]
Returns true if this option is "un-safe".
pub fn is_no_cache_key(self) -> bool
[src]
Returns true if this option is a "no-cache-key" option.
pub fn option_value_type(self) -> OptionValueType
[src]
Returns the expected value type for this option number.
pub fn is_ok_in_request(self) -> bool
[src]
Returns true if this option is allowed in requests, false if it is prohibited in requests.
pub fn is_ok_in_response(self) -> bool
[src]
Returns true if this option is allowed in responses, false if it is prohibited in responses.
pub fn is_repeatable(self) -> bool
[src]
Returns true if multiple instances of this option are allowed, false if only one instance is allowed.
pub fn static_name(self) -> Option<&'static str>
[src]
Attempts to return a Some(&'static str)
containing the name of the option.
If the option number isn't recognized, this method returns None
.
pub fn fmt_with_value(self, f: &mut Formatter, value: &[u8]) -> Result
[src]
Writes out the name of this option along with a text debugging description of the value associated with this option.
Trait Implementations
impl Clone for OptionNumber
[src]
fn clone(&self) -> OptionNumber
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for OptionNumber
[src]
impl Ord for OptionNumber
[src]
fn cmp(&self, other: &OptionNumber) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
[src]
clamp
)Restrict a value to a certain interval. Read more
impl PartialOrd<OptionNumber> for OptionNumber
[src]
fn partial_cmp(&self, other: &OptionNumber) -> Option<Ordering>
[src]
fn lt(&self, other: &OptionNumber) -> bool
[src]
fn le(&self, other: &OptionNumber) -> bool
[src]
fn gt(&self, other: &OptionNumber) -> bool
[src]
fn ge(&self, other: &OptionNumber) -> bool
[src]
impl PartialOrd<u16> for OptionNumber
[src]
fn partial_cmp(&self, other: &u16) -> Option<Ordering>
[src]
#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Copy for OptionNumber
[src]
impl Eq for OptionNumber
[src]
impl PartialEq<OptionNumber> for OptionNumber
[src]
fn eq(&self, other: &OptionNumber) -> bool
[src]
fn ne(&self, other: &OptionNumber) -> bool
[src]
impl PartialEq<u16> for OptionNumber
[src]
fn eq(&self, other: &u16) -> bool
[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl Hash for OptionNumber
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Add<u16> for OptionNumber
[src]
type Output = Self
The resulting type after applying the +
operator.
fn add(self, other: u16) -> Self
[src]
impl Sub<OptionNumber> for OptionNumber
[src]
type Output = u16
The resulting type after applying the -
operator.
fn sub(self, other: OptionNumber) -> u16
[src]
impl Display for OptionNumber
[src]
impl Debug for OptionNumber
[src]
Auto Trait Implementations
impl Unpin for OptionNumber
impl Sync for OptionNumber
impl Send for OptionNumber
impl UnwindSafe for OptionNumber
impl RefUnwindSafe for OptionNumber
Blanket Implementations
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.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T> From<T> for 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.
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,