Custom Codecs
Warning
Using custom codecs requires the user to manage format versioning of their custom codecs.
They are a great tool for experimentation, but think carefully before using them in production.
Encoder
openzl.ext.CustomEncoder
__module__ = 'openzl.ext'
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__init__()
method descriptor
init(self) -> None
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
encode()
method descriptor
encode(self, arg: openzl.ext.EncoderState, /) -> None
multi_input_description()
method descriptor
multi_input_description(self) -> openzl.ext.MultiInputCodecDescription
openzl.ext.EncoderState
__module__ = 'openzl.ext'
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
inputs
property
(self) -> list[openzl.ext.Input]
__init__(*args, **kwargs)
method descriptor
Initialize self. See help(type(self)) for accurate signature.
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
create_output()
method descriptor
create_output(self, arg0: int, arg1: int, arg2: int, /) -> openzl.ext.Output
get_cparam()
method descriptor
get_cparam(self, arg: openzl.ext.CParam, /) -> int
get_local_int_param()
method descriptor
get_local_int_param(self, arg: int, /) -> int | None
get_local_param()
method descriptor
get_local_param(self, arg: int, /) -> bytes | None
send_codec_header()
method descriptor
send_codec_header(self, arg: bytes, /) -> None
Decoder
openzl.ext.CustomDecoder
__module__ = 'openzl.ext'
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__init__()
method descriptor
init(self) -> None
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
decode()
method descriptor
decode(self, arg: openzl.ext.DecoderState, /) -> None
multi_input_description()
method descriptor
multi_input_description(self) -> openzl.ext.MultiInputCodecDescription
openzl.ext.DecoderState
__module__ = 'openzl.ext'
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
codec_header
property
(self) -> bytes
singleton_inputs
property
(self) -> list[openzl.ext.Input]
variable_inputs
property
(self) -> list[openzl.ext.Input]
__init__(*args, **kwargs)
method descriptor
Initialize self. See help(type(self)) for accurate signature.
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
create_output()
method descriptor
create_output(self, arg0: int, arg1: int, arg2: int, /) -> openzl.ext.Output