f
decodeWord(): DecodedWord
bytes: Uint8Array,
options?: { offset?: number; }
Decodes a word from MikroTik API format
f
encodeWord(content: string | Uint8Array): EncodedWord
Encodes a word (string or bytes) into MikroTik API format
T
DecodedWord = { word: string; bytesRead: number; }
Decoded word value with metadata
-
bytesRead: number
Total bytes read (length prefix + content)
-
word: string
The decoded UTF-8 string
T
EncodedWord = Uint8Array
Encoded word as a Uint8Array
Usage
import * as mod from "encoding/word.ts";