#[non_exhaustive]pub enum RecoverError {
NoObjects,
NoCatalog,
Encrypted,
TooManyEntries,
}Expand description
Why a recovery attempt could not produce a document — every case a named, fail-clean refusal (R27), never a partial/garbage document.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NoObjects
The scan found no confirmable N G obj objects at all — this is
not a recoverable PDF (the “not a PDF” outcome on the header path).
NoCatalog
Objects were recovered but no /Type /Catalog could be found by
any route — a document root is required (§7.7.2), so recovery
refuses rather than return a rootless document.
Encrypted
The recovered trailer carries /Encrypt (§7.6). pdfcer has no
security handler, so a broken-xref-and-encrypted file is
refused post-rebuild for the same reason the clean path refuses it.
TooManyEntries
The synthesized entries exceeded MAX_XREF_ENTRIES (R25 guard) —
an obj-token-dense adversarial file stops here rather than
allocating without bound.
Trait Implementations§
Source§impl Clone for RecoverError
impl Clone for RecoverError
Source§impl Debug for RecoverError
impl Debug for RecoverError
Source§impl Display for RecoverError
impl Display for RecoverError
impl Eq for RecoverError
Source§impl Error for RecoverError
impl Error for RecoverError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()