ByteArray.take


Description:

[ Version ( since = "2.32" ) ]
public ByteArray.take (owned uint8[] data)

Create byte array containing the data.

The data will be owned by the array and will be freed with g_free, i.e. it could be allocated using strdup.

Do not use it if data.length is greater than g_maxuint. ByteArray stores the length of its data in uint, which may be shorter than size_t.

Parameters:

data

byte data for the array

len

length of data

Returns:

a new ByteArray




2022 vala-language.org