|
Original Symbian headers
Selected EUSER, Window Server, networking, graphics and device declarations
|
A template specialisation base class for arrays of fixed length untyped objects. More...
#include <e32base.h>
Public Member Functions | |
| CArrayFix (TBufRep aRep, TInt aRecordLength, TInt aGranularity) | |
| const TAny * | At (TInt anIndex) const |
| Gets a pointer to the untyped element located at the specified position within the array. | |
| const TAny * | End (TInt anIndex) const |
| Gets a pointer to the first byte following the end of the contiguous region containing the element at the specfied position within the array. | |
| const TAny * | Back (TInt anIndex) const |
| Gets a pointer to the beginning of a contiguous region. | |
| TAny * | At (TInt anIndex) |
| Gets a pointer to the untyped element located at the specified position within the array. | |
| TAny * | End (TInt anIndex) |
| Gets a pointer to the first byte following the end of the contiguous region containing the element at the specfied position within the array. | |
| TAny * | Back (TInt anIndex) |
| Gets a pointer to the beginning of a contiguous region. | |
| void | AppendL (const TAny *aPtr) |
| Appends the specified untyped element onto the end of the array. | |
| void | AppendL (const TAny *aPtr, TInt aCount) |
| Appends one or more untyped elements onto the end of the array. | |
| TAny * | ExtendL () |
| Expands the array by the length of one element at the end of the array and returns a pointer to this new location. | |
Public Member Functions inherited from CArrayFixBase | |
| IMPORT_C | ~CArrayFixBase () |
| Destructor. | |
| TInt | Count () const |
| Gets the number of elements held in the array. | |
| TInt | Length () const |
| Gets the length of an element. | |
| IMPORT_C void | Compress () |
| Compresses the array. | |
| IMPORT_C void | Reset () |
| Deletes all elements from the array and frees the memory allocated to the array buffer. | |
| IMPORT_C TInt | Sort (TKeyArrayFix &aKey) |
| Sorts the elements of the array into key sequence. | |
| IMPORT_C TAny * | At (TInt anIndex) const |
| Index into the array. | |
| IMPORT_C TAny * | End (TInt anIndex) const |
| Return a pointer past contiguous elements starting at anIndex. | |
| IMPORT_C TAny * | Back (TInt anIndex) const |
| Return a pointer to contiguous elements before anIndex. | |
| IMPORT_C void | Delete (TInt anIndex) |
| Deletes a single element from the array at a specified position. | |
| IMPORT_C void | Delete (TInt anIndex, TInt aCount) |
| Deletes one or more contiguous elements from the array, starting at a specific position. | |
| IMPORT_C TAny * | ExpandL (TInt anIndex) |
| Expand the array to make room for a new record at anIndex. | |
| IMPORT_C TInt | Find (const TAny *aPtr, TKeyArrayFix &aKey, TInt &anIndex) const |
| Find in the array using a sequential search. | |
| IMPORT_C TInt | FindIsq (const TAny *aPtr, TKeyArrayFix &aKey, TInt &anIndex) const |
| Find in the array using a binary search. | |
| IMPORT_C void | InsertL (TInt anIndex, const TAny *aPtr) |
| Insert a record into the array. | |
| IMPORT_C void | InsertL (TInt anIndex, const TAny *aPtr, TInt aCount) |
| Insert aCount records into the array. | |
| IMPORT_C TInt | InsertIsqL (const TAny *aPtr, TKeyArrayFix &aKey) |
| Insert in sequence, no duplicates allowed. | |
| IMPORT_C TInt | InsertIsqAllowDuplicatesL (const TAny *aPtr, TKeyArrayFix &aKey) |
| Insert in sequence, allow duplicates. | |
| IMPORT_C void | ResizeL (TInt aCount, const TAny *aPtr) |
| Resize the array to contain aCount records, copying a record into any new slots. | |
Public Member Functions inherited from CBase | |
| CBase () | |
| Default constructor. | |
| virtual IMPORT_C | ~CBase () |
| Virtual destructor. | |
| TAny * | operator new (TUint aSize, TAny *aBase) __NO_THROW |
| Initialises the object to binary zeroes. | |
| TAny * | operator new (TUint aSize) __NO_THROW |
| Allocates the object from the heap and then initialises its contents to binary zeroes. | |
| TAny * | operator new (TUint aSize, TLeave) |
| Allocates the object from the heap and then initialises its contents to binary zeroes. | |
| TAny * | operator new (TUint aSize, TUint aExtraSize) __NO_THROW |
| Allocates the object from the heap and then initialises its contents to binary zeroes. | |
| TAny * | operator new (TUint aSize, TLeave, TUint aExtraSize) |
| Allocates the object from the heap and then initialises its contents to binary zeroes. | |
Additional Inherited Members | |
Static Public Member Functions inherited from CBase | |
| static IMPORT_C void | Delete (CBase *aPtr) |
| Deletes the specified object. | |
Protected Member Functions inherited from CArrayFixBase | |
| IMPORT_C | CArrayFixBase (TBufRep aRep, TInt aRecordLength, TInt aGranularity) |
| Constructor. | |
| IMPORT_C void | InsertRepL (TInt anIndex, const TAny *aPtr, TInt aReplicas) |
| Insert aReplicas copies of a record into the array. | |
| IMPORT_C void | SetKey (TKeyArrayFix &aKey) const |
| Set the key data. | |
| IMPORT_C void | SetReserveFlatL (TInt aCount) |
| Reserve space to contain aCount items. | |
Protected Member Functions inherited from CBase | |
| virtual IMPORT_C TInt | Extension_ (TUint aExtensionId, TAny *&a0, TAny *a1) |
| Extension function. | |
Static Protected Member Functions inherited from CArrayFixBase | |
| static IMPORT_C TInt | CountR (const CBase *aPtr) |
| Return the number of items in the array. | |
| static IMPORT_C const TAny * | AtR (const CBase *aPtr, TInt anIndex) |
| Return the address of an item in the array. | |
A template specialisation base class for arrays of fixed length untyped objects.
The public functions provide standard array behaviour.
The class is always derived from and is never instantiated explicitly.
|
inline |
|
inline |
Appends the specified untyped element onto the end of the array.
| aPtr | A pointer to an untyped element to be appended. |
Leave condition: KErrNoMemory The function may attempt to expand the array buffer. If there is insufficient memory available, the function leaves, in which case the array is left in the state it was in before the call.
(generated from Symbian Developer Library)
|
inline |
Appends one or more untyped elements onto the end of the array.
| aPtr | A pointer to the first of the contiguous untyped elements to be appended. |
| aCount | The number of contiguous elements located at aPtr to be appended. |
Leave condition: KErrNoMemory The function may attempt to expand the array buffer. If there is insufficient memory available, the function leaves, in which case the array is left in the state it was in before the call.
Panic condition: E32USER-CBase 23, if aCount is negative.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the untyped element located at the specified position within the array.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32User-CBase 21, if anIndex is negative or is greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the untyped element located at the specified position within the array.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32User-CBase 21, if anIndex is negative or is greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the beginning of a contiguous region.
For flat buffers, the function always returns a pointer to the beginning of the buffer.
For segmented buffers, the function returns a pointer to the beginning of the segment for all elements in that segment except the first. If the element at the specified position is the first in a segment, then the function returns a pointer the beginning of the previous segment.
For the first element in the array, the function returns a NULL pointer.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32User-CBase 21, if anIndex is negative or is greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the beginning of a contiguous region.
For flat buffers, the function always returns a pointer to the beginning of the buffer.
For segmented buffers, the function returns a pointer to the beginning of the segment for all elements in that segment except the first. If the element at the specified position is the first in a segment, then the function returns a pointer the beginning of the previous segment.
For the first element in the array, the function returns a NULL pointer.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32User-CBase 21, if anIndex is negative or is greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the first byte following the end of the contiguous region containing the element at the specfied position within the array.
For flat buffers, the pointer always points to the first byte following the end of the buffer.
For segmented buffers, the pointer always points to the first byte following the end of the segment which contains the element.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32USER-CBase 21, if anIndex is negative or greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Gets a pointer to the first byte following the end of the contiguous region containing the element at the specfied position within the array.
For flat buffers, the pointer always points to the first byte following the end of the buffer.
For segmented buffers, the pointer always points to the first byte following the end of the segment which contains the element.
| anIndex | The position of the element within the array. The position is relative to zero; i.e. zero implies the first element in the array. |
Panic condition: E32USER-CBase 21, if anIndex is negative or greater than or equal to the number of objects currently within the array.
(generated from Symbian Developer Library)
|
inline |
Expands the array by the length of one element at the end of the array and returns a pointer to this new location.
As elements are untyped, no construction is possible and the content of the new location remains undefined.
Leave condition: KErrNoMemory The function may attempt to expand the array buffer. If there is insufficient memory available, the function leaves, in which case the array is left in the state it was in before the call.
(generated from Symbian Developer Library)