MiniQuake

src/miniquake/protocol_text.ml

Package
miniquake.protocol_text
Reachable
Yes

Declarations

decodeBytes

function decodeBytes(data)

Decodes bytes for `miniquake.protocol_text`.

ParameterTypeDefaultDescription
datadynamic—Input data consumed by the operation.

View source

encodeBytes

function encodeBytes(text)

Encodes bytes for `miniquake.protocol_text`.

ParameterTypeDefaultDescription
textdynamic—Text to parse or process.

View source

encodedLength

function encodedLength(text)

Encode and write d length.

ParameterTypeDefaultDescription
textdynamic—Text to parse or process.

View source

roundTripBytes

function roundTripBytes(data)

Return round trip bytes derived from the active module state.

ParameterTypeDefaultDescription
datadynamic—Input data consumed by the operation.

View source

TEXT_ABI

const TEXT_ABI = "quake_latin1_cstring_v1"

Defines the text abi value used by `miniquake.protocol_text`.

View source

truncate

function truncate(text, maximum)

Truncate by Quake bytes rather than MiniLang's UTF-8 storage bytes. This is the newName[15]=0 behavior needed by Host_Name_f while preserving every extended Quake byte 0x80..0xff.

ParameterTypeDefaultDescription
textdynamic—Text to parse or process.
maximumdynamic—Largest accepted value.

View source