pub struct Pool<'prepared, 'model, 'document> { /* private fields */ }Expand description
Complete original source pool. Every readable timestamp envelope is held once; CRL/OCSP models are parsed once, and index creation never replays them.
Implementations§
Source§impl<'p, 'm, 'd> Pool<'p, 'm, 'd>
impl<'p, 'm, 'd> Pool<'p, 'm, 'd>
Sourcepub fn read(
prepared: &'p Preparation<'m, 'd>,
operation: &Reader<'d>,
) -> Result<Self>
pub fn read( prepared: &'p Preparation<'m, 'd>, operation: &Reader<'d>, ) -> Result<Self>
Read the entire original source pool, preserving unreadable token and known material findings. Resource/depth/processing refusal is terminal, releases partial models and never returns a successful partial pool.
Sourcepub fn prepared(&self) -> &'p Preparation<'m, 'd>
pub fn prepared(&self) -> &'p Preparation<'m, 'd>
Same source preparation; the pool cannot be relabelled to another root.
Sourcepub fn token_faults(&self) -> &[(Node, ReadError)]
pub fn token_faults(&self) -> &[(Node, ReadError)]
Every unreadable original timestamp and its retained failure.
Sourcepub fn open(&self) -> &[Open<'d>]
pub fn open(&self) -> &[Open<'d>]
Every original unknown or known-malformed material enclosure.
Sourcepub fn crls(&self) -> usize
pub fn crls(&self) -> usize
Number of original readable complete/delta CRL values, without parsing.
Sourcepub fn crl<W: Work>(
&self,
ordinal: usize,
work: &W,
) -> Result<Option<&CertificateList<'d>>>
pub fn crl<W: Work>( &self, ordinal: usize, work: &W, ) -> Result<Option<&CertificateList<'d>>>
One original parsed CRL under current metadata admission. Authentication and status processing reuse this model; they must not reparse its bytes.
Sourcepub fn ocsp_responses(&self) -> usize
pub fn ocsp_responses(&self) -> usize
Number of original readable basic responses in their real wire format.
Sourcepub fn ocsp<W: Work>(
&self,
ordinal: usize,
work: &W,
) -> Result<Option<&BasicResponse<'d>>>
pub fn ocsp<W: Work>( &self, ordinal: usize, work: &W, ) -> Result<Option<&BasicResponse<'d>>>
One first-read basic response, from a whole RFC5940 envelope or actual Annex A revocation-values. The index retains its real placement.
Sourcepub fn token<W: Work>(
&self,
ordinal: usize,
work: &W,
) -> Result<Option<&Token<'d>>>
pub fn token<W: Work>( &self, ordinal: usize, work: &W, ) -> Result<Option<&Token<'d>>>
Original timestamp envelopes, indexed by original preparation ordinal. This paid query reuses the parsed envelope rather than reparsing it.
Sourcepub fn with_token<R, E>(
&self,
ordinal: usize,
operation: &Reader<'d>,
visitor: impl for<'scope> FnOnce(Context<'scope, 'm, 'd>) -> Result<R, E>,
) -> Result<R, VisitError<E>>
pub fn with_token<R, E>( &self, ordinal: usize, operation: &Reader<'d>, visitor: impl for<'scope> FnOnce(Context<'scope, 'm, 'd>) -> Result<R, E>, ) -> Result<R, VisitError<E>>
Visit a previously parsed original token with the current operation. Uses its saved parser/encoding/depth, with no second envelope parse.
Sourcepub fn index_for_archive<'source, Q>(
&'source self,
archive: ArchiveView<'_, 'm, 'd, '_>,
query: &Q,
) -> Result<Index<'source, 'm, 'd, Q::Work>, ArchiveIndexError>
pub fn index_for_archive<'source, Q>( &'source self, archive: ArchiveView<'_, 'm, 'd, '_>, query: &Q, ) -> Result<Index<'source, 'm, 'd, Q::Work>, ArchiveIndexError>
Build material scope for the actual successful archive owner, including a historical counter or parallel root. Sources are the same original pool; no signature is replayed and no parsed artifact is cloned.
Sourcepub fn index<'source, Q>(
&'source self,
query: &Q,
) -> Result<Index<'source, 'm, 'd, Q::Work>, IndexError<Node>>
pub fn index<'source, Q>( &'source self, query: &Q, ) -> Result<Index<'source, 'm, 'd, Q::Work>, IndexError<Node>>
Build the one exact-artifact index from actual root/token locations. Models remain borrowed; no certificate/CRL/status byte copy or parser replay occurs. The current query funds all new hashing/probing/storage.