Skip to main content

ZL_MIEncoderDesc

Struct ZL_MIEncoderDesc 

Source
#[repr(C)]
pub struct ZL_MIEncoderDesc { pub gd: ZL_MIGraphDesc, pub transform_f: ZL_MIEncoderFn, pub localParams: ZL_LocalParams, pub name: *const c_char, pub trStateMgr: ZL_CodecStateManager, pub opaque: ZL_OpaquePtr, pub materializer: ZL_MaterializerDesc, pub dictMat: ZL_MaterializerDesc2, pub dictID: ZL_DictID, pub mparamMat: ZL_MaterializerDesc2, pub mparam: ZL_MParam, }

Fields§

§gd: ZL_MIGraphDesc§transform_f: ZL_MIEncoderFn§localParams: ZL_LocalParams§name: *const c_char§trStateMgr: ZL_CodecStateManager§opaque: ZL_OpaquePtr

Optionally an opaque pointer that can be queried with ZL_Encoder_getOpaquePtr(). OpenZL unconditionally takes ownership of this pointer, even if registration fails, and it lives for the lifetime of the compressor.

§materializer: ZL_MaterializerDesc

Optional materializer descriptor for materialized local params. If both materializeFn and dematerializeFn are non-null, the materializer will be used to create materialized objects from local params.

§dictMat: ZL_MaterializerDesc2

Optional materializer descriptor for materialized dicts. If both materializeFn and dematerializeFn are non-null, the materializer will be used to create materialized objects. Create a node with materialization using ZL_Compressor_parameterizeNode().

§dictID: ZL_DictID

Optional dictionary ID associated with this encoder. When set, identifies the dictionary that this encoder requires. A zero-initialized value (ZL_DICT_ID_NULL) means no dictionary is associated.

§mparamMat: ZL_MaterializerDesc2

Optional materializer for compression-only materialized parameters (MParams). If materializeFn is non-null, it will be called during compressor deserialization to create the materialized object from the serialized MParam blob. Unlike dicts, MParams are NOT required at decompression time.

§mparam: ZL_MParam

Optional MParam associated with this encoder. The provided content blob will be materialized as dictated by @p mparamMat . OpenZL will not take ownership of the content provided. The caller is free to free the buffer anytime after registering the MIEncoder with ZL_Compressor_registerMIEncoder().

Trait Implementations§

Source§

impl Clone for ZL_MIEncoderDesc

Source§

fn clone(&self) -> ZL_MIEncoderDesc

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for ZL_MIEncoderDesc

Source§

impl Debug for ZL_MIEncoderDesc

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.