![]() |
Murl Engine Lua Addon API
Version 1.0 beta
|
The BufferedData object extends the Data object for appending data portions to pre-allocated memory.
The memory grows by doubling the memory size if needed. If the memory exceeds a size threshold, the memory grows in steps of the threshold. The size threshold is ignored if the size threshold is 0.
The default constructor. Initializes the write position to 0 and the size threshold to 64 kilobytes.
Murl.BufferedData new()
Release the data. Free (delete) the memory and set the write position to 0.
ReleaseData()
Set the memory growing size threshold. See AppendData().
SetSizeThreshold(Integer sizeThreshold)
sizeThreshold | The memory growing size threshold in bytes. |
Get the memory growing size threshold. See AppendData().
Integer GetSizeThreshold()
Set the write position.
SetWritePosition(Integer bytePosition)
bytePosition | The write position in bytes. |
Get the write position.
Integer GetWritePosition()
Trim the memory size to the write position.
Murl.Data Trim()