Blame qtools/qarray.doc

Packit Service 50c9f2
/****************************************************************************
Packit Service 50c9f2
** 
Packit Service 50c9f2
**
Packit Service 50c9f2
** QArray class documentation
Packit Service 50c9f2
**
Packit Service 50c9f2
** Copyright (C) 1992-2000 Trolltech AS.  All rights reserved.
Packit Service 50c9f2
**
Packit Service 50c9f2
** This file is part of the Qt GUI Toolkit.
Packit Service 50c9f2
**
Packit Service 50c9f2
** This file may be distributed under the terms of the Q Public License
Packit Service 50c9f2
** as defined by Trolltech AS of Norway and appearing in the file
Packit Service 50c9f2
** LICENSE.QPL included in the packaging of this file.
Packit Service 50c9f2
**
Packit Service 50c9f2
** This file may be distributed and/or modified under the terms of the
Packit Service 50c9f2
** GNU General Public License version 2 as published by the Free Software
Packit Service 50c9f2
** Foundation and appearing in the file LICENSE.GPL included in the
Packit Service 50c9f2
** packaging of this file.
Packit Service 50c9f2
**
Packit Service 50c9f2
** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition
Packit Service 50c9f2
** licenses may use this file in accordance with the Qt Commercial License
Packit Service 50c9f2
** Agreement provided with the Software.
Packit Service 50c9f2
**
Packit Service 50c9f2
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
Packit Service 50c9f2
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
Packit Service 50c9f2
**
Packit Service 50c9f2
** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
Packit Service 50c9f2
**   information about Qt Commercial License Agreements.
Packit Service 50c9f2
** See http://www.trolltech.com/qpl/ for QPL licensing information.
Packit Service 50c9f2
** See http://www.trolltech.com/gpl/ for GPL licensing information.
Packit Service 50c9f2
**
Packit Service 50c9f2
** Contact info@trolltech.com if any conditions of this licensing are
Packit Service 50c9f2
** not clear to you.
Packit Service 50c9f2
**
Packit Service 50c9f2
**********************************************************************/
Packit Service 50c9f2
Packit Service 50c9f2
Packit Service 50c9f2
/*****************************************************************************
Packit Service 50c9f2
  QArray documentation
Packit Service 50c9f2
 *****************************************************************************/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \class QArray qarray.h
Packit Service 50c9f2
  \brief The QArray class is a template class that provides arrays of simple types.
Packit Service 50c9f2
Packit Service 50c9f2
  \ingroup tools
Packit Service 50c9f2
Packit Service 50c9f2
  QArray is implemented as a template class. Define a template
Packit Service 50c9f2
  instance QArray\<X\> to create an array that contains X items.
Packit Service 50c9f2
Packit Service 50c9f2
  QArray stores the array elements directly in the array. It can only
Packit Service 50c9f2
  deal with simple types, i.e. C++ types, structs and classes that have
Packit Service 50c9f2
  no constructors, destructors or virtual functions.  QArray uses
Packit Service 50c9f2
  bitwise operations to copy and compare array elements.
Packit Service 50c9f2
Packit Service 50c9f2
  The QVector collection class is also a kind of array.  Like most
Packit Service 50c9f2
  \link collection.html collection classes\endlink, it has pointers to the
Packit Service 50c9f2
  contained items.
Packit Service 50c9f2
Packit Service 50c9f2
  QArray uses explicit \link shclass.html sharing\endlink with a reference
Packit Service 50c9f2
  count.  If more than one array share common data, and one array is
Packit Service 50c9f2
  modified, all arrays will be modified.
Packit Service 50c9f2
Packit Service 50c9f2
  The benefit of sharing is that a program does not need to duplicate
Packit Service 50c9f2
  data when it is not required, which results in less memory usage and
Packit Service 50c9f2
  less copying of data.
Packit Service 50c9f2
Packit Service 50c9f2
  Example:
Packit Service 50c9f2
  \code
Packit Service 50c9f2
    #include <qarray.h>
Packit Service 50c9f2
    #include <stdio.h>
Packit Service 50c9f2
Packit Service 50c9f2
    QArray<int> fib( int num )			// returns fibonacci array
Packit Service 50c9f2
    {
Packit Service 50c9f2
	ASSERT( num > 2 );
Packit Service 50c9f2
	QArray<int> f( num );			// array of ints
Packit Service 50c9f2
Packit Service 50c9f2
        f[0] = f[1] = 1;			// initialize first two numbers
Packit Service 50c9f2
	for ( int i=2; i
Packit Service 50c9f2
	    f[i] = f[i-1] + f[i-2];	
Packit Service 50c9f2
Packit Service 50c9f2
	return f;
Packit Service 50c9f2
    }
Packit Service 50c9f2
Packit Service 50c9f2
    void main()
Packit Service 50c9f2
    {
Packit Service 50c9f2
	QArray<int> a = fib( 6 );		// get 6 first fibonaccis
Packit Service 50c9f2
	int i;
Packit Service 50c9f2
Packit Service 50c9f2
	for ( i=0; i
Packit Service 50c9f2
	    prinf( "%d: %d\n", i, a[i] );
Packit Service 50c9f2
Packit Service 50c9f2
	printf( "1 is found %d time(s)\n", a.contains(1) );
Packit Service 50c9f2
	printf( "5 is found at index %d\n", a.find(5) );
Packit Service 50c9f2
    }
Packit Service 50c9f2
  \endcode
Packit Service 50c9f2
Packit Service 50c9f2
  Program output:
Packit Service 50c9f2
  \code
Packit Service 50c9f2
	0: 1
Packit Service 50c9f2
	1: 1
Packit Service 50c9f2
	2: 2
Packit Service 50c9f2
	3: 3
Packit Service 50c9f2
	4: 5
Packit Service 50c9f2
	5: 8
Packit Service 50c9f2
	1 is found 2 times
Packit Service 50c9f2
	5 is found at index 4
Packit Service 50c9f2
  \endcode
Packit Service 50c9f2
Packit Service 50c9f2
  Note about using QArray for manipulating structs or classes:
Packit Service 50c9f2
  Compilers will often pad the size of structs of odd sizes up to the
Packit Service 50c9f2
  nearest word boundary. This will then be the size QArray will use
Packit Service 50c9f2
  for its bitwise element comparisons. Since the remaining bytes will
Packit Service 50c9f2
  typically be uninitialized, this can cause find() etc. to fail to
Packit Service 50c9f2
  find the element. Example:
Packit Service 50c9f2
Packit Service 50c9f2
  \code
Packit Service 50c9f2
    struct MyStruct
Packit Service 50c9f2
    {
Packit Service 50c9f2
      short i;                    // 2 bytes
Packit Service 50c9f2
      char c;                     // 1 byte
Packit Service 50c9f2
    };                            // sizeof(MyStruct) may be padded to 4 bytes
Packit Service 50c9f2
Packit Service 50c9f2
    QArray<MyStruct> a(1);
Packit Service 50c9f2
    a[0].i = 5;
Packit Service 50c9f2
    a[0].c = 't';
Packit Service 50c9f2
Packit Service 50c9f2
    MyStruct x;
Packit Service 50c9f2
    x.i = '5';
Packit Service 50c9f2
    x.c = 't';
Packit Service 50c9f2
    int i = a.find( x );          // May return -1 if the pad bytes differ
Packit Service 50c9f2
  \endcode
Packit Service 50c9f2
Packit Service 50c9f2
  To workaround this, make sure that you use a struct where sizeof()
Packit Service 50c9f2
  returns the same as the sum of the sizes of the members, either by
Packit Service 50c9f2
  changing the types of the struct members or by adding dummy members.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa \link shclass.html Shared Classes\endlink
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::QArray()
Packit Service 50c9f2
  Constructs a null array.
Packit Service 50c9f2
  \sa isNull()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::QArray( int size )
Packit Service 50c9f2
  Constructs an array with room for \e size elements.
Packit Service 50c9f2
  Makes a null array if \e size == 0.
Packit Service 50c9f2
Packit Service 50c9f2
  Note that the elements are not initialized.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa resize(), isNull()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::QArray( const QArray<type> &a )
Packit Service 50c9f2
  Constructs a shallow copy of \e a.
Packit Service 50c9f2
  \sa assign()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::QArray( int, int )
Packit Service 50c9f2
  Constructs an array without allocating array space.
Packit Service 50c9f2
  The arguments should be (0, 0). Use at own risk.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::~QArray()
Packit Service 50c9f2
  Dereferences the array data and deletes it if this was the last
Packit Service 50c9f2
  reference.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::operator=( const QArray<type> &a )
Packit Service 50c9f2
  Assigns a shallow copy of \e a to this array and returns a reference
Packit Service 50c9f2
  to this array.
Packit Service 50c9f2
Packit Service 50c9f2
  Equivalent to assign( a ).
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn type *QArray::data() const
Packit Service 50c9f2
  Returns a pointer to the actual array data.
Packit Service 50c9f2
Packit Service 50c9f2
  The array is a null array if data() == 0 (null pointer).
Packit Service 50c9f2
Packit Service 50c9f2
  \sa isNull()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn uint QArray::nrefs() const
Packit Service 50c9f2
  Returns the reference count for the shared array data. This reference count
Packit Service 50c9f2
  is always greater than zero.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn uint QArray::size() const
Packit Service 50c9f2
  Returns the size of the array (max number of elements).
Packit Service 50c9f2
Packit Service 50c9f2
  The array is a null array if size() == 0.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa isNull(), resize()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn uint QArray::count() const
Packit Service 50c9f2
  Returns the same as size().
Packit Service 50c9f2
Packit Service 50c9f2
  \sa size()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::isEmpty() const
Packit Service 50c9f2
  Returns TRUE if the array is empty, i.e. size() == 0, otherwise FALSE.
Packit Service 50c9f2
Packit Service 50c9f2
  isEmpty() is equivalent with isNull() for QArray.  Note that this is not
Packit Service 50c9f2
  the case for QCString::isEmpty().
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::isNull() const
Packit Service 50c9f2
  Returns TRUE if the array is null, otherwise FALSE.
Packit Service 50c9f2
Packit Service 50c9f2
  A null array has size() == 0 and data() == 0.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::resize( uint size )
Packit Service 50c9f2
  Resizes (expands or shrinks) the array to \e size elements. The array
Packit Service 50c9f2
  becomes a null array if \e size == 0.
Packit Service 50c9f2
Packit Service 50c9f2
  Returns TRUE if successful, or FALSE if the memory cannot be allocated.
Packit Service 50c9f2
Packit Service 50c9f2
  New elements will not be initialized.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa size()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::truncate( uint pos )
Packit Service 50c9f2
  Truncates the array at position \e pos.
Packit Service 50c9f2
Packit Service 50c9f2
  Returns TRUE if successful, or FALSE if the memory cannot be allocated.
Packit Service 50c9f2
Packit Service 50c9f2
  Equivalent to resize(\e pos).
Packit Service 50c9f2
Packit Service 50c9f2
  \sa resize()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::fill( const type &v, int size )
Packit Service 50c9f2
  Fills the array with the value \e v. If \e size is specified as different
Packit Service 50c9f2
  from -1, then the array will be resized before filled.
Packit Service 50c9f2
Packit Service 50c9f2
  Returns TRUE if successful, or FALSE if the memory cannot be allocated
Packit Service 50c9f2
  (only when \e size != -1).
Packit Service 50c9f2
Packit Service 50c9f2
  \sa resize()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn void QArray::detach()
Packit Service 50c9f2
  Detaches this array from shared array data, i.e. makes a private, deep
Packit Service 50c9f2
  copy of the data.
Packit Service 50c9f2
Packit Service 50c9f2
  Copying will only be performed if the
Packit Service 50c9f2
  \link nrefs() reference count\endlink is greater than one.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa copy()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> QArray::copy() const
Packit Service 50c9f2
  Returns a deep copy of this array.
Packit Service 50c9f2
  \sa detach(), duplicate()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::assign( const QArray<type> &a )
Packit Service 50c9f2
  Shallow copy. Dereferences the current array and references the data
Packit Service 50c9f2
  contained in \e a instead. Returns a reference to this array.
Packit Service 50c9f2
  \sa operator=()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::assign( const type *data, uint size )
Packit Service 50c9f2
  Shallow copy. Dereferences the current array and references the
Packit Service 50c9f2
  array data \e data, which contains \e size elements.
Packit Service 50c9f2
  Returns a reference to this array.
Packit Service 50c9f2
Packit Service 50c9f2
  Do not delete \e data later, QArray takes care of that.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::duplicate( const QArray<type> &a )
Packit Service 50c9f2
  Deep copy. Dereferences the current array and obtains a copy of the data
Packit Service 50c9f2
  contained in \e a instead. Returns a reference to this array.
Packit Service 50c9f2
  \sa copy()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::duplicate( const type *data, uint size )
Packit Service 50c9f2
  Deep copy. Dereferences the current array and obtains a copy of the
Packit Service 50c9f2
  array data \e data instead.  Returns a reference to this array.
Packit Service 50c9f2
  \sa copy()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray<type> &QArray::setRawData( const type *data, uint size )
Packit Service 50c9f2
Packit Service 50c9f2
  Sets raw data and returns a reference to the array.
Packit Service 50c9f2
Packit Service 50c9f2
  Dereferences the current array and sets the new array data to \e data and
Packit Service 50c9f2
  the new array size to \e size.  Do not attempt to resize or re-assign the
Packit Service 50c9f2
  array data when raw data has been set.
Packit Service 50c9f2
  Call resetRawData(d,len) to reset the array.
Packit Service 50c9f2
Packit Service 50c9f2
  Setting raw data is useful because it sets QArray data without allocating
Packit Service 50c9f2
  memory or copying data.
Packit Service 50c9f2
Packit Service 50c9f2
  Example I (intended use):
Packit Service 50c9f2
  \code
Packit Service 50c9f2
    static char bindata[] = { 231, 1, 44, ... };
Packit Service 50c9f2
    QByteArray	a;
Packit Service 50c9f2
    a.setRawData( bindata, sizeof(bindata) );	// a points to bindata
Packit Service 50c9f2
    QDataStream s( a, IO_ReadOnly );		// open on a's data
Packit Service 50c9f2
    s >> <something>;				// read raw bindata
Packit Service 50c9f2
    a.resetRawData( bindata, sizeof(bindata) ); // finished
Packit Service 50c9f2
  \endcode
Packit Service 50c9f2
Packit Service 50c9f2
  Example II (you don't want to do this):
Packit Service 50c9f2
  \code
Packit Service 50c9f2
    static char bindata[] = { 231, 1, 44, ... };
Packit Service 50c9f2
    QByteArray	a, b;
Packit Service 50c9f2
    a.setRawData( bindata, sizeof(bindata) );	// a points to bindata
Packit Service 50c9f2
    a.resize( 8 );				// will crash
Packit Service 50c9f2
    b = a;					// will crash
Packit Service 50c9f2
    a[2] = 123;					// might crash
Packit Service 50c9f2
      // forget to resetRawData - will crash
Packit Service 50c9f2
  \endcode
Packit Service 50c9f2
Packit Service 50c9f2
  \warning If you do not call resetRawData(), QArray will attempt to
Packit Service 50c9f2
  deallocate or reallocate the raw data, which might not be too good.
Packit Service 50c9f2
  Be careful.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa resetRawData()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn void QArray::resetRawData( const type *data, uint size )
Packit Service 50c9f2
  Resets raw data that was set using setRawData().
Packit Service 50c9f2
Packit Service 50c9f2
  The arguments must be the data and length that were passed to
Packit Service 50c9f2
  setRawData().	 This is for consistency checking.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa setRawData()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn int QArray::find( const type &v, uint index ) const
Packit Service 50c9f2
  Finds the first occurrence of \e v, starting at position \e index.
Packit Service 50c9f2
Packit Service 50c9f2
  Returns the position of \e v, or -1 if \e v could not be found.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa contains()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn int QArray::contains( const type &v ) const
Packit Service 50c9f2
  Returns the number of times \e v occurs in the array.
Packit Service 50c9f2
  \sa find()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn void QArray::sort()
Packit Service 50c9f2
  Sorts the array elements in ascending order, using bitwise
Packit Service 50c9f2
  comparison (memcmp()).
Packit Service 50c9f2
Packit Service 50c9f2
  \sa bsearch()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn int QArray::bsearch( const type &v ) const
Packit Service 50c9f2
  In a sorted array, finds the first occurrence of \e v using binary
Packit Service 50c9f2
  search. For a sorted array, this is generally much faster than
Packit Service 50c9f2
  find(), which does a linear search.
Packit Service 50c9f2
Packit Service 50c9f2
  Returns the position of \e v, or -1 if \e v could not be found.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa sort(), find()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn type &QArray::operator[]( int index ) const
Packit Service 50c9f2
  Returns a reference to the element at position \e index in the array.
Packit Service 50c9f2
Packit Service 50c9f2
  This can be used to both read and set an element.  Equivalent to at().
Packit Service 50c9f2
Packit Service 50c9f2
  \sa at()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn type &QArray::at( uint index ) const
Packit Service 50c9f2
  Returns a reference to the element at position \e index in the array.
Packit Service 50c9f2
Packit Service 50c9f2
  This can be used to both read and set an element.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa operator[]()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn QArray::operator const type *() const
Packit Service 50c9f2
  Cast operator.  Returns a pointer to the array.
Packit Service 50c9f2
  \sa data()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::operator==( const QArray<type> &a ) const
Packit Service 50c9f2
  Returns TRUE if this array is equal to \e a, otherwise FALSE.
Packit Service 50c9f2
Packit Service 50c9f2
  The two arrays are bitwise compared.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa operator!=()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn bool QArray::operator!=( const QArray<type> &a ) const
Packit Service 50c9f2
  Returns TRUE if this array is different from \e a, otherwise FALSE.
Packit Service 50c9f2
Packit Service 50c9f2
  The two arrays are bitwise compared.
Packit Service 50c9f2
Packit Service 50c9f2
  \sa operator==()
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn Iterator QArray::begin()
Packit Service 50c9f2
  Returns an iterator pointing at the beginning of this array.
Packit Service 50c9f2
  This iterator can be used as the iterators of QValueList and QMap
Packit Service 50c9f2
  for example. In fact it does not only behave like a usual pointer:
Packit Service 50c9f2
  It is a pointer.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn Iterator QArray::end()
Packit Service 50c9f2
  Returns an iterator pointing behind the last element of this array.
Packit Service 50c9f2
  This iterator can be used as the iterators of QValueList and QMap
Packit Service 50c9f2
  for example. In fact it does not only behave like a usual pointer:
Packit Service 50c9f2
  It is a pointer.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn ConstIterator QArray::begin() const
Packit Service 50c9f2
  Returns a const iterator pointing at the beginning of this array.
Packit Service 50c9f2
  This iterator can be used as the iterators of QValueList and QMap
Packit Service 50c9f2
  for example. In fact it does not only behave like a usual pointer:
Packit Service 50c9f2
  It is a pointer.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \fn ConstIterator QArray::end() const
Packit Service 50c9f2
  Returns a const iterator pointing behind the last element of this array.
Packit Service 50c9f2
  This iterator can be used as the iterators of QValueList and QMap
Packit Service 50c9f2
  for example. In fact it does not only behave like a usual pointer:
Packit Service 50c9f2
  It is a pointer.
Packit Service 50c9f2
*/
Packit Service 50c9f2
Packit Service 50c9f2
Packit Service 50c9f2
/*****************************************************************************
Packit Service 50c9f2
  QByteArray documentation
Packit Service 50c9f2
 *****************************************************************************/
Packit Service 50c9f2
Packit Service 50c9f2
/*!
Packit Service 50c9f2
  \class QByteArray qcstring.h
Packit Service 50c9f2
  \brief The QByteArray class provides an array of bytes.
Packit Service 50c9f2
Packit Service 50c9f2
  \inherit QArray
Packit Service 50c9f2
Packit Service 50c9f2
  \ingroup tools
Packit Service 50c9f2
Packit Service 50c9f2
  The QByteArray class provides an explicitly shared array of
Packit Service 50c9f2
  bytes. It is useful for manipulating memory areas with custom
Packit Service 50c9f2
  data. QByteArray is implemented as QArray<char>. See the QArray
Packit Service 50c9f2
  documentation for further information.
Packit Service 50c9f2
*/