pub struct CompatibilityTable { /* private fields */ }
Expand description
A table of options that are supported locally or remotely, and their current state.
Implementations§
Source§impl CompatibilityTable
impl CompatibilityTable
Sourcepub const ENABLED_LOCAL: u8 = 1u8
pub const ENABLED_LOCAL: u8 = 1u8
Option is locally supported.
Sourcepub const ENABLED_REMOTE: u8 = 2u8
pub const ENABLED_REMOTE: u8 = 2u8
Option is remotely supported.
Sourcepub const LOCAL_STATE: u8 = 4u8
pub const LOCAL_STATE: u8 = 4u8
Option is currently enabled locally.
Sourcepub const REMOTE_STATE: u8 = 8u8
pub const REMOTE_STATE: u8 = 8u8
Option is currently enabled remotely.
pub fn new() -> Self
Sourcepub fn from_options(values: &[(u8, u8)]) -> Self
pub fn from_options(values: &[(u8, u8)]) -> Self
Sourcepub fn support_local(&mut self, option: u8)
pub fn support_local(&mut self, option: u8)
Enable local support for an option.
Sourcepub fn support_remote(&mut self, option: u8)
pub fn support_remote(&mut self, option: u8)
Enable remote support for an option.
Sourcepub fn get_option(&self, option: u8) -> CompatibilityEntry
pub fn get_option(&self, option: u8) -> CompatibilityEntry
Retrieve a CompatbilityEntry
generated from the current state of the option value.
Sourcepub fn set_option(&mut self, option: u8, entry: CompatibilityEntry)
pub fn set_option(&mut self, option: u8, entry: CompatibilityEntry)
Set an option value by getting the bitmask from a CompatibilityEntry
.
Sourcepub fn reset_states(&mut self)
pub fn reset_states(&mut self)
Reset all negotiated states
Trait Implementations§
Source§impl Clone for CompatibilityTable
impl Clone for CompatibilityTable
Source§fn clone(&self) -> CompatibilityTable
fn clone(&self) -> CompatibilityTable
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for CompatibilityTable
impl RefUnwindSafe for CompatibilityTable
impl Send for CompatibilityTable
impl Sync for CompatibilityTable
impl Unpin for CompatibilityTable
impl UnwindSafe for CompatibilityTable
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more