Skip to main content

Module zero_copy

Module zero_copy 

Source
Available on crate feature zero-copy only.
Expand description

Relative pointer system for zero-copy nested structures

Structs§

RelativePtr
A relative pointer that stores the offset from its own address to the target data. This allows zero-copy deserialization without runtime allocations.
ZeroArray
A zero-copy array collection equivalent to [T; N].
ZeroBuilderalloc
A builder for zero-copy structures.
ZeroSlice
A zero-copy slice collection conceptually equivalent to &[T] or Vec<T>.
ZeroStr
A dynamically sized zero-copy string conceptually equivalent to &str or String.
ZeroString
A zero-copy string type with compile-time known max capacity, stored inline.

Traits§

DeepValidator
A trait for deep validation of zero-copy structures, recursively checking all pointers.
StaticSize
Indicates that a type has a fixed size known at compile time. This allows us to perform bounds checking efficiently.
Validator
A trait for validating zero-copy types.
ZeroCopy
A marker trait indicating that a type has a fixed, predictable layout (e.g., #[repr(C)]) and contains no padding bytes or invalid bit patterns allowing safe zero-copy casting.
ZeroCopyBuilder
A trait for types that can be built into a zero-copy structure.
ZeroCopyType
A trait for zero-copy types that defines their preferred builder type.