ByteArray.this

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 g_strdup().

Do not use it if @len is greater than %G_MAXUINT. #GByteArray stores the length of its data in #guint, which may be shorter than #gsize.

  1. this(GByteArray* gByteArray, bool ownedRef)
  2. this()
  3. this(ubyte[] data)
    class ByteArray
    this
    (
    ubyte[] data
    )

Parameters

data ubyte[]

byte data for the array

Return Value

a new #GByteArray

Throws

ConstructionException GTK+ fails to create the object.

Meta

Since

2.32