KaitaiStruct (kaitai_struct v0.1.2)
KaitaiStruct
is the Elixir runtime for Kaitai
Summary
Functions
Takes a binary and returns a new binary with the occurrences of the matching byte stripped from the end
Searches binary for the term and if found, returns a binary terminated at that location. If not found, returns input binary
Takes a binary and specifies its' encoding
Currently accepted encodings
Runs modulo on inputs
Elixir strings will be assumed to be encoded in UTF-8 format unless otherwise specified
Functions
Takes a binary and returns a new binary with the occurrences of the matching byte stripped from the end
Searches binary for the term and if found, returns a binary terminated at that location. If not found, returns input binary
@spec bytes_to_str(bytes :: binary(), encoding :: String.t()) :: {:ok, binary()} | {:error, :unsupported_encoding} | {:error, {:encoding_error, term()}}
Takes a binary and specifies its' encoding
@spec encodings() :: map()
Currently accepted encodings:
- UTF-8
- UTF-16
- UTF-16LE
- UTF-16BE
- UTF-32
Runs modulo on inputs
@spec native_encoding() :: :utf8
Elixir strings will be assumed to be encoded in UTF-8 format unless otherwise specified