Struct x86::segmentation::SegmentSelector [−]
pub struct SegmentSelector { /* fields omitted */ }Methods
impl SegmentSelector
impl SegmentSelectorpub const RPL_0: SegmentSelector
RPL_0: SegmentSelector = SegmentSelector{bits: 0,}
Requestor Privilege Level
pub const RPL_1: SegmentSelector
RPL_1: SegmentSelector = SegmentSelector{bits: 1,}
pub const RPL_2: SegmentSelector
RPL_2: SegmentSelector = SegmentSelector{bits: 2,}
pub const RPL_3: SegmentSelector
RPL_3: SegmentSelector = SegmentSelector{bits: 3,}
pub const TI_GDT: SegmentSelector
TI_GDT: SegmentSelector = SegmentSelector{bits: 0 << 2,}
Table Indicator (TI) 0 means GDT is used.
pub const TI_LDT: SegmentSelector
TI_LDT: SegmentSelector = SegmentSelector{bits: 1 << 2,}
Table Indicator (TI) 1 means LDT is used.
pub fn empty() -> SegmentSelector
pub fn empty() -> SegmentSelectorReturns an empty set of flags.
pub fn all() -> SegmentSelector
pub fn all() -> SegmentSelectorReturns the set containing all flags.
pub fn bits(&self) -> u16
pub fn bits(&self) -> u16Returns the raw value of the flags currently stored.
pub fn from_bits(bits: u16) -> Option<SegmentSelector>
pub fn from_bits(bits: u16) -> Option<SegmentSelector>Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
pub fn from_bits_truncate(bits: u16) -> SegmentSelector
pub fn from_bits_truncate(bits: u16) -> SegmentSelectorConvert from underlying bit representation, dropping any bits that do not correspond to flags.
pub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> boolReturns true if no flags are currently stored.
pub fn is_all(&self) -> bool
pub fn is_all(&self) -> boolReturns true if all flags are currently set.
pub fn intersects(&self, other: SegmentSelector) -> bool
pub fn intersects(&self, other: SegmentSelector) -> boolReturns true if there are flags common to both self and other.
pub fn contains(&self, other: SegmentSelector) -> bool
pub fn contains(&self, other: SegmentSelector) -> boolReturns true all of the flags in other are contained within self.
pub fn insert(&mut self, other: SegmentSelector)
pub fn insert(&mut self, other: SegmentSelector)Inserts the specified flags in-place.
pub fn remove(&mut self, other: SegmentSelector)
pub fn remove(&mut self, other: SegmentSelector)Removes the specified flags in-place.
pub fn toggle(&mut self, other: SegmentSelector)
pub fn toggle(&mut self, other: SegmentSelector)Toggles the specified flags in-place.
pub fn set(&mut self, other: SegmentSelector, value: bool)
pub fn set(&mut self, other: SegmentSelector, value: bool)Inserts or removes the specified flags depending on the passed value.
impl SegmentSelector[src]
impl SegmentSelectorpub const fn new(index: u16, rpl: Ring) -> SegmentSelector[src]
pub const fn new(index: u16, rpl: Ring) -> SegmentSelectorCreate a new SegmentSelector
Arguments
index- index in GDT or LDT array.rpl- Requested privilege level of the selector
pub const fn from_raw(bits: u16) -> SegmentSelector[src]
pub const fn from_raw(bits: u16) -> SegmentSelectorMake a new segment selector from a untyped u16 value.
Trait Implementations
impl Copy for SegmentSelector
impl Copy for SegmentSelectorimpl PartialEq for SegmentSelector
impl PartialEq for SegmentSelectorfn eq(&self, other: &SegmentSelector) -> bool
fn eq(&self, other: &SegmentSelector) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &SegmentSelector) -> bool
fn ne(&self, other: &SegmentSelector) -> boolThis method tests for !=.
impl Eq for SegmentSelector
impl Eq for SegmentSelectorimpl Clone for SegmentSelector
impl Clone for SegmentSelectorfn clone(&self) -> SegmentSelector
fn clone(&self) -> SegmentSelectorReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl PartialOrd for SegmentSelector
impl PartialOrd for SegmentSelectorfn partial_cmp(&self, other: &SegmentSelector) -> Option<Ordering>
fn partial_cmp(&self, other: &SegmentSelector) -> Option<Ordering>This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &SegmentSelector) -> bool
fn lt(&self, other: &SegmentSelector) -> boolThis method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &SegmentSelector) -> bool
fn le(&self, other: &SegmentSelector) -> boolThis method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, other: &SegmentSelector) -> bool
fn gt(&self, other: &SegmentSelector) -> boolThis method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, other: &SegmentSelector) -> bool
fn ge(&self, other: &SegmentSelector) -> boolThis method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl Ord for SegmentSelector
impl Ord for SegmentSelectorfn cmp(&self, other: &SegmentSelector) -> Ordering
fn cmp(&self, other: &SegmentSelector) -> OrderingThis method returns an Ordering between self and other. Read more
fn max(self, other: Self) -> Self1.21.0[src]
fn max(self, other: Self) -> SelfCompares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self1.21.0[src]
fn min(self, other: Self) -> SelfCompares and returns the minimum of two values. Read more
impl Hash for SegmentSelector
impl Hash for SegmentSelectorfn hash<__H: Hasher>(&self, state: &mut __H)
fn hash<__H: Hasher>(&self, state: &mut __H)Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, Feeds a slice of this type into the given [Hasher]. Read more
impl Debug for SegmentSelector
impl Debug for SegmentSelectorimpl Binary for SegmentSelector
impl Binary for SegmentSelectorimpl Octal for SegmentSelector
impl Octal for SegmentSelectorimpl LowerHex for SegmentSelector
impl LowerHex for SegmentSelectorimpl UpperHex for SegmentSelector
impl UpperHex for SegmentSelectorimpl BitOr for SegmentSelector
impl BitOr for SegmentSelectortype Output = SegmentSelector
The resulting type after applying the | operator.
fn bitor(self, other: SegmentSelector) -> SegmentSelector
fn bitor(self, other: SegmentSelector) -> SegmentSelectorReturns the union of the two sets of flags.
impl BitOrAssign for SegmentSelector
impl BitOrAssign for SegmentSelectorfn bitor_assign(&mut self, other: SegmentSelector)
fn bitor_assign(&mut self, other: SegmentSelector)Adds the set of flags.
impl BitXor for SegmentSelector
impl BitXor for SegmentSelectortype Output = SegmentSelector
The resulting type after applying the ^ operator.
fn bitxor(self, other: SegmentSelector) -> SegmentSelector
fn bitxor(self, other: SegmentSelector) -> SegmentSelectorReturns the left flags, but with all the right flags toggled.
impl BitXorAssign for SegmentSelector
impl BitXorAssign for SegmentSelectorfn bitxor_assign(&mut self, other: SegmentSelector)
fn bitxor_assign(&mut self, other: SegmentSelector)Toggles the set of flags.
impl BitAnd for SegmentSelector
impl BitAnd for SegmentSelectortype Output = SegmentSelector
The resulting type after applying the & operator.
fn bitand(self, other: SegmentSelector) -> SegmentSelector
fn bitand(self, other: SegmentSelector) -> SegmentSelectorReturns the intersection between the two sets of flags.
impl BitAndAssign for SegmentSelector
impl BitAndAssign for SegmentSelectorfn bitand_assign(&mut self, other: SegmentSelector)
fn bitand_assign(&mut self, other: SegmentSelector)Disables all flags disabled in the set.
impl Sub for SegmentSelector
impl Sub for SegmentSelectortype Output = SegmentSelector
The resulting type after applying the - operator.
fn sub(self, other: SegmentSelector) -> SegmentSelector
fn sub(self, other: SegmentSelector) -> SegmentSelectorReturns the set difference of the two sets of flags.
impl SubAssign for SegmentSelector
impl SubAssign for SegmentSelectorfn sub_assign(&mut self, other: SegmentSelector)
fn sub_assign(&mut self, other: SegmentSelector)Disables all flags enabled in the set.
impl Not for SegmentSelector
impl Not for SegmentSelectortype Output = SegmentSelector
The resulting type after applying the ! operator.
fn not(self) -> SegmentSelector
fn not(self) -> SegmentSelectorReturns the complement of this set of flags.
impl Extend<SegmentSelector> for SegmentSelector
impl Extend<SegmentSelector> for SegmentSelectorfn extend<T: IntoIterator<Item = SegmentSelector>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = SegmentSelector>>(&mut self, iterator: T)Extends a collection with the contents of an iterator. Read more
impl FromIterator<SegmentSelector> for SegmentSelector
impl FromIterator<SegmentSelector> for SegmentSelectorfn from_iter<T: IntoIterator<Item = SegmentSelector>>(
iterator: T
) -> SegmentSelector
fn from_iter<T: IntoIterator<Item = SegmentSelector>>(
iterator: T
) -> SegmentSelectorCreates a value from an iterator. Read more
impl Display for SegmentSelector[src]
impl Display for SegmentSelectorAuto Trait Implementations
impl Send for SegmentSelector
impl Send for SegmentSelectorimpl Sync for SegmentSelector
impl Sync for SegmentSelector