Skip to content

Binary (Class)

Binary data type for flexible input handling.

This type is not intended to be instantiated directly from Python. It serves as a helper type that allows Rust functions to accept binary data in multiple convenient forms from Python.

Accepts
  • str: A hexadecimal string (e.g., "deadbeef").
  • bytes: Python bytes object.
  • list[int]: A list of byte values (0-255).