Module codec

Module codec 

Source
Expand description

Codec utilities for TDS protocol encoding and decoding.

This module provides low-level encoding and decoding utilities used throughout the TDS protocol implementation.

Functionsยง

read_b_varchar
Read a length-prefixed UTF-16LE string.
read_null_terminated_ascii
Read a null-terminated ASCII string.
read_us_varchar
Read a length-prefixed UTF-16LE string with 2-byte length.
read_utf16_string
Read a UTF-16LE string of specified character length.
utf16_byte_len
Calculate the byte length of a UTF-16 encoded string.
write_b_varchar
Write a length-prefixed UTF-16LE string (1-byte length).
write_us_varchar
Write a length-prefixed UTF-16LE string (2-byte length).
write_utf16_string
Write a UTF-16LE string without length prefix.