itom 2.2.1
ito::ByteArray::Data Struct Reference

basic data container for class ByteArray that is implicitely shared over multiple instances of ByteArray of the same content More...

List of all members.

Public Attributes

int m_ref
char * m_pData
char m_buffer [1]

Detailed Description

basic data container for class ByteArray that is implicitely shared over multiple instances of ByteArray of the same content

The address of the real character array is stored in m_pData. The data buffer itself starts at m_buffer and continues at the end of the struct. Therefore, ByteArray allocates memory for Data that has the length of data + the length of the character array to store. The number of ByteArray instances that have access to exactly the same Data container is stored in the reference counter m_ref.

The basic principle of the implicit sharing is taken from QByteArray.


Member Data Documentation

start of character array buffer. The real buffer is longer than one char value, therefore no member must be appended after this point.

pointer to charcter array that begins at m_buffer

reference counter for implicit sharing (0: means one reference, ...)


The documentation for this struct was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Properties Friends