#[repr(i32)]pub enum ProtectionScheme {
Unspecified = 0,
Cenc = 1_667_591_779,
Cbc1 = 1_667_392_305,
Cens = 1_667_591_795,
Cbcs = 1_667_392_371,
}
Variants§
Unspecified = 0
Defaults to ‘cenc’
Cenc = 1_667_591_779
‘cenc’ (AES-CTR) = 0x63656E63
Cbc1 = 1_667_392_305
‘cbc1’ (AES-CBC) = 0x63626331
Cens = 1_667_591_795
‘cens’ (AES-CTR subsample) =
Cbcs = 1_667_392_371
0x63656E73
‘cbcs’ (AES-CBC subsample) = 0x63626373
Implementations§
source§impl ProtectionScheme
impl ProtectionScheme
sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
source§impl Clone for ProtectionScheme
impl Clone for ProtectionScheme
source§fn clone(&self) -> ProtectionScheme
fn clone(&self) -> ProtectionScheme
Returns a copy 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 moresource§impl Debug for ProtectionScheme
impl Debug for ProtectionScheme
source§impl Default for ProtectionScheme
impl Default for ProtectionScheme
source§fn default() -> ProtectionScheme
fn default() -> ProtectionScheme
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for ProtectionScheme
impl<'de> Deserialize<'de> for ProtectionScheme
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl From<ProtectionScheme> for i32
impl From<ProtectionScheme> for i32
source§fn from(value: ProtectionScheme) -> i32
fn from(value: ProtectionScheme) -> i32
Converts to this type from the input type.
source§impl Hash for ProtectionScheme
impl Hash for ProtectionScheme
source§impl Ord for ProtectionScheme
impl Ord for ProtectionScheme
source§fn cmp(&self, other: &ProtectionScheme) -> Ordering
fn cmp(&self, other: &ProtectionScheme) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for ProtectionScheme
impl PartialEq for ProtectionScheme
source§impl PartialOrd for ProtectionScheme
impl PartialOrd for ProtectionScheme
source§impl Serialize for ProtectionScheme
impl Serialize for ProtectionScheme
source§impl TryFrom<i32> for ProtectionScheme
impl TryFrom<i32> for ProtectionScheme
source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
The type returned in the event of a conversion error.
source§fn try_from(value: i32) -> Result<ProtectionScheme, UnknownEnumValue>
fn try_from(value: i32) -> Result<ProtectionScheme, UnknownEnumValue>
Performs the conversion.
impl Copy for ProtectionScheme
impl Eq for ProtectionScheme
impl StructuralPartialEq for ProtectionScheme
Auto Trait Implementations§
impl Freeze for ProtectionScheme
impl RefUnwindSafe for ProtectionScheme
impl Send for ProtectionScheme
impl Sync for ProtectionScheme
impl Unpin for ProtectionScheme
impl UnwindSafe for ProtectionScheme
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)