Expand description
Bounded ownership and decompression limits for untrusted decode input.
DecodeArena owns stable buffers, DecodeContext owns session state,
and View provides bounded navigation within one address space.
Modules§
- collect
- Collections whose length is proven against the input.
- tree
- XML and JSON parsing with nesting depth charged to the decode session.
- zstd
- Window-admitted Zstandard streams.
Structs§
- Bounded
Count - A count proven to fit in the unread input.
- Budget
Exhausted - A work budget reached its limit.
- Byte
Range - A half-open byte range
[start, end)within one space. - Companion
- A file that a
Companionssource opened. - Decode
Arena - Owns stable byte buffers allocated during a decode.
- Decode
Checkpoint - Immutable resource state from which independent decode tasks can start.
- Decode
Context - Shared monotonic decode state.
- Decode
Policy - Decode mode and resource ceilings.
- Decode
Space Rebinding - Rebinds a task’s derived address spaces at its composition position.
- Decode
Trace - Charge totals between ordered budget observations and expansion boundaries. A refused group causes the caller to execute the original operations.
- Depth
Guard - A guard holding one unit of recursive nesting depth.
- Expand
Writer - Writes decompressed output under incremental charging.
- Inspect
Options - Resource options for container inspection.
- Parse
Error - A classified failure after commitment, with its location.
- Resource
Limit - A resource refusal.
- Resource
Limits - Absolute resource ceilings.
- Source
Location - An offset qualified by its address space.
- SpaceId
- Names one address space within a single decode.
- View
- A bounded window over one address space.
- Whole
Input - A detection prefix that holds every byte of its source.
- Work
Budget - A local work counter for one bounded search or iteration.
- Work
Budget Recursion Guard - RAII guard for one recursive frame of a
WorkBudget.
Enums§
- Companion
Load - The result of a companion request.
- Decode
Depth - How much of the source document a decode transfers.
- Decode
Mode - Whether a successful decode may report mandatory transfer losses.
- Expand
Spec - How much output an expansion is expected to produce.
- Parse
Error Kind - The classified reason a committed parse failed.
- Resource
Dimension - Which resource a limit governs.
- Resource
Failure - Why a resource request failed.
Traits§
- Companions
- A source of the files that a decoded input names by path.
Functions§
- bounded_
len - Converts a declared element count into a safe
Veccapacity. - id_
from_ index - Narrows the position of one item already held in memory to the
u32an IR identifier, order or index field is stated in. - index_
from_ u32 - Widens a 32-bit count, identifier or index to a
usizeindex. - index_
from_ u64 - Narrows an offset stated in a wire
u64to an index into bytes held in memory. - u64_
from_ index - Widens an in-memory length, index or capacity to a
u64. - unique_
index - Indexes
entriesby key, mapping a key that occurs more than once toNone. - work_
units - The work a step over
itemsowes aWorkBudget.