Skip to main content

Skip

Enum Skip 

Source
pub enum Skip {
    EncryptDict,
    XrefStream,
    ExternalStream,
    ClearMetadata,
    IdentityCryptFilter,
}
Expand description

Why an object’s bytes are left alone.

Returned rather than a bare bool so the reason can be asserted in tests and reported in diagnostics — “this stream was skipped” is not a useful fact without “because it is a cross-reference stream”.

Variants§

§

EncryptDict

E3/E2 — this is the /Encrypt dictionary. §7.6.1: the encryption dictionary “shall not” be encrypted, and neither are its strings; it has to be readable before any key exists.

§

XrefStream

E5 — a cross-reference stream. §7.5.8.2 exempts it because the bootstrap order (xref → trailer → /Encrypt → authenticate → decrypt) means nothing on the path to the key may itself require the key (T6).

§

ExternalStream

E6 — the data is in another file (/F), so there are no bytes here. Note the asymmetry: an embedded file stream is encrypted.

§

ClearMetadata

E8 — the document metadata stream, left in the clear by /EncryptMetadata false. This changes the key as well (Algorithm 2 step (f), T11), so the two must agree or nothing decrypts.

§

IdentityCryptFilter

E8, second spelling — a /Crypt filter naming /Identity. Unlike /EncryptMetadata, this does not change the file key (T23); both mechanisms exist and a document may use either.

Trait Implementations§

Source§

impl Clone for Skip

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Skip

Source§

impl Debug for Skip

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Skip

Source§

impl PartialEq for Skip

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Skip

Auto Trait Implementations§

§

impl Forget for Skip

§

impl Freeze for Skip

§

impl Move for Skip

§

impl RefUnwindSafe for Skip

§

impl Send for Skip

§

impl Sync for Skip

§

impl Unpin for Skip

§

impl UnsafeUnpin for Skip

§

impl UnwindSafe for Skip

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.