new_take_data


Description:

public static Buffer new_take_data (owned uint8[] data)

Create a new buffer and set the data and size of the buffer to data and data.length respectively.

data will be freed when the buffer is unreffed, so this function transfers ownership of data to the new buffer.

Parameters:

data

data for the new buffer

len

the length of data

Returns:

A newly allocated buffer with data and of size data.length.




2022 vala-language.org