Skip to main content

Reading

Struct Reading 

Source
pub struct Reading<'v, 's, N, D, G, S: RangeSource> { /* private fields */ }
Expand description

Inventory derived only inside the actual member-producing XML scope. This does not attest complete ODF encryption/extension semantics or signatures.

Implementations§

Source§

impl<'v, 's, N: Copy, D: Copy, G: Copy, S: RangeSource> Reading<'v, 's, N, D, G, S>

Source

pub fn source(&self) -> &Member<'v, 's, S>

Actual complete member from which this XML inventory was produced.

Source

pub fn snapshot(&self) -> Snapshot<D, G>

Actual original XML source and generation.

Source

pub fn root(&self) -> N

Actual whole-document root, preserving its parent context.

Source

pub fn format(&self) -> Format

Explicit selected inventory vocabulary.

Source

pub fn entries(&self) -> &[Entry<'v, 's, N, S>]

All original declarations in document order.

Source

pub fn faults(&self) -> &[Fault<N, S::Document, S::Generation>]

All original negative/unassessed declarations and missing obligations.

Source

pub async fn check_root_media<W: Work>( &self, work: &W, ) -> Result<RootMedia, ReadFailure<S::Error, S::Document, S::Generation>>

ODF1.2 part3 §3.3 requires exact equality of the package root’s media attribute with the complete mimetype member. MIME essence equality is insufficient. Duplicate roots/names remain unavailable, never selected.

§Panics

An internal immutable name-catalogue invariant fails if its unique candidate cannot be selected from that same catalogue.

Auto Trait Implementations§

§

impl<'v, 's, N, D, G, S> !Freeze for Reading<'v, 's, N, D, G, S>

§

impl<'v, 's, N, D, G, S> !RefUnwindSafe for Reading<'v, 's, N, D, G, S>

§

impl<'v, 's, N, D, G, S> !Send for Reading<'v, 's, N, D, G, S>

§

impl<'v, 's, N, D, G, S> !Sync for Reading<'v, 's, N, D, G, S>

§

impl<'v, 's, N, D, G, S> !UnwindSafe for Reading<'v, 's, N, D, G, S>

§

impl<'v, 's, N, D, G, S> Unpin for Reading<'v, 's, N, D, G, S>
where Member<'v, 's, S>: Unpin, Snapshot<D, G>: Unpin, N: Unpin, OwnedVec<Entry<'v, 's, N, S>>: Unpin, OwnedVec<Fault<N, <S as RangeSource>::Document, <S as RangeSource>::Generation>>: Unpin,

§

impl<'v, 's, N, D, G, S> UnsafeUnpin for Reading<'v, 's, N, D, G, S>

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> 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, 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.