Struct xbe::cert::MediaTypes [−]
pub struct MediaTypes { /* fields omitted */ }
Media type mask used for the allowed_media
field in Certificate
.
Methods
impl MediaTypes
impl MediaTypes
pub const HARD_DISK: MediaTypes
HARD_DISK: MediaTypes = MediaTypes{bits: 1,}
pub const DVD_X2: MediaTypes
DVD_X2: MediaTypes = MediaTypes{bits: 2,}
pub const DVD_CD: MediaTypes
DVD_CD: MediaTypes = MediaTypes{bits: 4,}
pub const CD: MediaTypes
CD: MediaTypes = MediaTypes{bits: 8,}
pub const DVD_5_RO: MediaTypes
DVD_5_RO: MediaTypes = MediaTypes{bits: 16,}
pub const DVD_9_RO: MediaTypes
DVD_9_RO: MediaTypes = MediaTypes{bits: 32,}
pub const DVD_5_RW: MediaTypes
DVD_5_RW: MediaTypes = MediaTypes{bits: 64,}
pub const DVD_9_RW: MediaTypes
DVD_9_RW: MediaTypes = MediaTypes{bits: 128,}
pub const DONGLE: MediaTypes
DONGLE: MediaTypes = MediaTypes{bits: 256,}
pub const MEDIA_BOARD: MediaTypes
MEDIA_BOARD: MediaTypes = MediaTypes{bits: 512,}
pub const NONSECURE_HARD_DISK: MediaTypes
NONSECURE_HARD_DISK: MediaTypes = MediaTypes{bits: 1073741824,}
pub const NONSECURE_MODE: MediaTypes
NONSECURE_MODE: MediaTypes = MediaTypes{bits: 2147483648,}
pub fn empty() -> MediaTypes
pub fn empty() -> MediaTypes
Returns an empty set of flags.
pub fn all() -> MediaTypes
pub fn all() -> MediaTypes
Returns the set containing all flags.
pub fn bits(&self) -> u32
pub fn bits(&self) -> u32
Returns the raw value of the flags currently stored.
pub fn from_bits(bits: u32) -> Option<MediaTypes>
pub fn from_bits(bits: u32) -> Option<MediaTypes>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
pub fn from_bits_truncate(bits: u32) -> MediaTypes
pub fn from_bits_truncate(bits: u32) -> MediaTypes
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
pub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Returns true
if no flags are currently stored.
pub fn is_all(&self) -> bool
pub fn is_all(&self) -> bool
Returns true
if all flags are currently set.
pub fn intersects(&self, other: MediaTypes) -> bool
pub fn intersects(&self, other: MediaTypes) -> bool
Returns true
if there are flags common to both self
and other
.
pub fn contains(&self, other: MediaTypes) -> bool
pub fn contains(&self, other: MediaTypes) -> bool
Returns true
all of the flags in other
are contained within self
.
pub fn insert(&mut self, other: MediaTypes)
pub fn insert(&mut self, other: MediaTypes)
Inserts the specified flags in-place.
pub fn remove(&mut self, other: MediaTypes)
pub fn remove(&mut self, other: MediaTypes)
Removes the specified flags in-place.
pub fn toggle(&mut self, other: MediaTypes)
pub fn toggle(&mut self, other: MediaTypes)
Toggles the specified flags in-place.
pub fn set(&mut self, other: MediaTypes, value: bool)
pub fn set(&mut self, other: MediaTypes, value: bool)
Inserts or removes the specified flags depending on the passed value.
Trait Implementations
impl Copy for MediaTypes
impl Copy for MediaTypes
impl PartialEq for MediaTypes
impl PartialEq for MediaTypes
fn eq(&self, other: &MediaTypes) -> bool
fn eq(&self, other: &MediaTypes) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &MediaTypes) -> bool
fn ne(&self, other: &MediaTypes) -> bool
This method tests for !=
.
impl Eq for MediaTypes
impl Eq for MediaTypes
impl Clone for MediaTypes
impl Clone for MediaTypes
fn clone(&self) -> MediaTypes
fn clone(&self) -> MediaTypes
Returns 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 MediaTypes
impl PartialOrd for MediaTypes
fn partial_cmp(&self, other: &MediaTypes) -> Option<Ordering>
fn partial_cmp(&self, other: &MediaTypes) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &MediaTypes) -> bool
fn lt(&self, other: &MediaTypes) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &MediaTypes) -> bool
fn le(&self, other: &MediaTypes) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &MediaTypes) -> bool
fn gt(&self, other: &MediaTypes) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &MediaTypes) -> bool
fn ge(&self, other: &MediaTypes) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for MediaTypes
impl Ord for MediaTypes
fn cmp(&self, other: &MediaTypes) -> Ordering
fn cmp(&self, other: &MediaTypes) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl Hash for MediaTypes
impl Hash for MediaTypes
fn 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 MediaTypes
impl Debug for MediaTypes
impl Binary for MediaTypes
impl Binary for MediaTypes
impl Octal for MediaTypes
impl Octal for MediaTypes
impl LowerHex for MediaTypes
impl LowerHex for MediaTypes
impl UpperHex for MediaTypes
impl UpperHex for MediaTypes
impl BitOr for MediaTypes
impl BitOr for MediaTypes
type Output = MediaTypes
The resulting type after applying the |
operator.
fn bitor(self, other: MediaTypes) -> MediaTypes
fn bitor(self, other: MediaTypes) -> MediaTypes
Returns the union of the two sets of flags.
impl BitOrAssign for MediaTypes
impl BitOrAssign for MediaTypes
fn bitor_assign(&mut self, other: MediaTypes)
fn bitor_assign(&mut self, other: MediaTypes)
Adds the set of flags.
impl BitXor for MediaTypes
impl BitXor for MediaTypes
type Output = MediaTypes
The resulting type after applying the ^
operator.
fn bitxor(self, other: MediaTypes) -> MediaTypes
fn bitxor(self, other: MediaTypes) -> MediaTypes
Returns the left flags, but with all the right flags toggled.
impl BitXorAssign for MediaTypes
impl BitXorAssign for MediaTypes
fn bitxor_assign(&mut self, other: MediaTypes)
fn bitxor_assign(&mut self, other: MediaTypes)
Toggles the set of flags.
impl BitAnd for MediaTypes
impl BitAnd for MediaTypes
type Output = MediaTypes
The resulting type after applying the &
operator.
fn bitand(self, other: MediaTypes) -> MediaTypes
fn bitand(self, other: MediaTypes) -> MediaTypes
Returns the intersection between the two sets of flags.
impl BitAndAssign for MediaTypes
impl BitAndAssign for MediaTypes
fn bitand_assign(&mut self, other: MediaTypes)
fn bitand_assign(&mut self, other: MediaTypes)
Disables all flags disabled in the set.
impl Sub for MediaTypes
impl Sub for MediaTypes
type Output = MediaTypes
The resulting type after applying the -
operator.
fn sub(self, other: MediaTypes) -> MediaTypes
fn sub(self, other: MediaTypes) -> MediaTypes
Returns the set difference of the two sets of flags.
impl SubAssign for MediaTypes
impl SubAssign for MediaTypes
fn sub_assign(&mut self, other: MediaTypes)
fn sub_assign(&mut self, other: MediaTypes)
Disables all flags enabled in the set.
impl Not for MediaTypes
impl Not for MediaTypes
type Output = MediaTypes
The resulting type after applying the !
operator.
fn not(self) -> MediaTypes
fn not(self) -> MediaTypes
Returns the complement of this set of flags.
impl Extend<MediaTypes> for MediaTypes
impl Extend<MediaTypes> for MediaTypes
fn extend<T: IntoIterator<Item = MediaTypes>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = MediaTypes>>(&mut self, iterator: T)
Extends a collection with the contents of an iterator. Read more
impl FromIterator<MediaTypes> for MediaTypes
impl FromIterator<MediaTypes> for MediaTypes
fn from_iter<T: IntoIterator<Item = MediaTypes>>(iterator: T) -> MediaTypes
fn from_iter<T: IntoIterator<Item = MediaTypes>>(iterator: T) -> MediaTypes
Creates a value from an iterator. Read more
Auto Trait Implementations
impl Send for MediaTypes
impl Send for MediaTypes
impl Sync for MediaTypes
impl Sync for MediaTypes