Struct gif::AnyExtension [−][src]
pub struct AnyExtension(pub u8);
A newtype wrapper around an arbitrary extension ID.
An extension is some amount of byte data organized in sub-blocks so that one can skip over it
without knowing the semantics. Though technically you likely want to use a Application
extension, the library tries to stay flexible here.
This allows us to customize the set of impls compared to a raw u8
. It also clarifies the
intent and gives some inherent methods for interoperability with known extension types.
Implementations
impl AnyExtension
[src]
pub fn into_known(self) -> Option<Extension>
[src]
Decode the label as a known extension.
Trait Implementations
impl Clone for AnyExtension
[src]
fn clone(&self) -> AnyExtension
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for AnyExtension
[src]
impl Debug for AnyExtension
[src]
impl Eq for AnyExtension
[src]
impl From<Extension> for AnyExtension
[src]
impl Hash for AnyExtension
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl PartialEq<AnyExtension> for AnyExtension
[src]
fn eq(&self, other: &AnyExtension) -> bool
[src]
fn ne(&self, other: &AnyExtension) -> bool
[src]
impl StructuralEq for AnyExtension
[src]
impl StructuralPartialEq for AnyExtension
[src]
Auto Trait Implementations
impl RefUnwindSafe for AnyExtension
impl Send for AnyExtension
impl Sync for AnyExtension
impl Unpin for AnyExtension
impl UnwindSafe for AnyExtension
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
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.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut 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.
pub 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>,