silk.build.encoding.
Owned schema output used by build keys, cached values, and compilation requests.
Import as Encoding with import silk.build.encoding as Encoding.
Public declarations: 4.
json#
pub effect fn json<T: Schema>(value: &T) -> Bytes
! SchemaError | WriterError | OutOfMemoryError
? &mut AllocatorEncodes one value as JSON without decoding or retaining a second representation.
toml#
pub effect fn toml<T: Schema>(value: &T) -> Bytes
! SchemaError | WriterError | OutOfMemoryError
? &mut AllocatorEncodes one record as TOML without decoding or retaining a second representation.
value#
pub effect fn value<T: Schema>(input: &T) -> Bytes
! SchemaError | WriterError | OutOfMemoryError
? &mut AllocatorEncodes a cached graph value, preserving each layer of nested options.
read#
pub effect fn read<T: Schema>(bytes: &[u8]) -> T
! SchemaError | OutOfMemoryError
? &mut AllocatorRestores a cached graph value with its exact optional structure.
Profiles: aarch64-apple-darwin, aarch64-unknown-linux-gnu, aarch64-unknown-linux-gnu-no-libc, x86_64-unknown-linux-gnu, x86_64-unknown-linux-gnu-no-libc, wasm32-unknown-unknown, wasm32-wasip1, wasm32-wasip2, x86_64-pc-windows-msvc, wasm64-unknown-unknown.