Construct a ByteVector, optionally from an existing Uint8Array.
Optionaldata: Uint8Array<ArrayBufferLike>Source bytes. If omitted, creates an empty vector.
When true (default) the data is copied; when false the
array is used directly (the caller must not mutate it afterwards).
OptionalpatternLength: numberChecks whether the last bytes of this vector partially match the
beginning of pattern. Returns the index within this vector where the
partial match starts, or -1 if no partial match is found.
Optionallength: numberReplace bytes. Supports both single-byte replacement and pattern-based replacement (ByteVector pattern → ByteVector replacement).
Base64-encode this vector's bytes and return the result as a new ByteVector containing the ASCII base64 text.
Decode an 80-bit IEEE 754 extended-precision float (big-endian). Layout: 1 sign bit, 15 exponent bits, 64 mantissa bits (with explicit integer bit).
Decode an 80-bit IEEE 754 extended-precision float (little-endian).
Return a new ByteVector where each byte is represented as two ASCII hex characters (lowercase).
OptionalmsbFirst: booleanOptionalmsbFirst: booleanOptionalmsbFirst: booleanConvert the byte data to a string using the given encoding.
OptionalmsbFirst: booleanOptionalmsbFirst: booleanOptionalmsbFirst: booleanOptionalmsbFirst: booleanStaticfromDecode a base64-encoded ByteVector. Returns an empty ByteVector on invalid input.
StaticfromCreate a ByteVector from a raw Uint8Array.
Source byte array.
Whether to copy the data (default true).
A new ByteVector wrapping the given bytes.
StaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfromStaticfrom
A binary data container wrapping a Uint8Array, providing methods for searching, manipulation, integer/float conversions, encoding, and comparison. This is a TypeScript port of TagLib's ByteVector class.