osncore::AlfPtrVector Class Reference

class osncore::AlfPtrVector : public osncore::IDeleter

Use STL vectorTemplate class for a pointer vector

osncore.lib
Since
S60 5.0 Draft AlfPtrVector

Inherits from

Public Member Functions
AlfPtrVector()
AlfPtrVector(uint)
~AlfPtrVector()
T *at(int)
boolautoDelete()
voidclear()
uint count()
T **data()
intfindRef(T *)
boolinsert(uint, T *)
boolisEmpty()
T *operator[](uint)
boolremove(uint)
boolresize(uint)
voidsetAutoDelete(bool)
uint size()
Private Member Functions
AlfPtrVector(const AlfPtrVector &)
voiddeleteItem(void *)
AlfPtrVector &operator=(const AlfPtrVector &)
Private Attributes
boolmDelItem
AlfPtrVectorImpl mImpl

Constructor & Destructor Documentation

AlfPtrVector()

AlfPtrVector()[inline]

Use STL vector Default constructor for vector. By default contents are automatically deleted when destructor is called.

Since
S60 5.0

AlfPtrVector(uint)

AlfPtrVector(uintaSize)[inline, explicit]

Use STL vector Constructor for vector with some default size. Size can be increased or decreased afterwards.

Since
S60 5.0

Parameters

uint aSizeDefault size of vector.

AlfPtrVector(const AlfPtrVector &)

AlfPtrVector(const AlfPtrVector &)[private]

Parameters

const AlfPtrVector &

~AlfPtrVector()

~AlfPtrVector()[inline]

Use STL vector Destructor.

Member Functions Documentation

at(int)

T *at(intaPos)const [inline]

Use STL vector Returns pointer to the item at given position in the vector.

Since
S60 5.0

Parameters

int aPosPosition from which item is queried.

autoDelete()

boolautoDelete()[inline]

Use STL vector Returns the value of auto delete property.

Since
S60 5.0

clear()

voidclear()[inline]

Deletes all items of vector.

Since
S60 5.0

count()

uint count()const [inline]

Use STL vector Returns number of items in vector.

Since
S60 5.0

data()

T **data()[inline]

Use STL vector Returns pointer to the raw data used by vector to stroe the items.

Since
S60 5.0

deleteItem(void *)

voiddeleteItem(void *aItem)[private, inline, virtual]

Parameters

void * aItem

findRef(T *)

intfindRef(T *aItem)[inline]

Use STL vector Returns the position of the item in the vector.

Since
S60 5.0

Parameters

T * aItemPointer to the item being searched in the vector.

insert(uint, T *)

boolinsert(uintaPos,
T *aItem
)[inline]

Use STL vector Inserts a new item at given position in the vector.

Since
S60 5.0

Parameters

uint aPosPosition at which item has to be inserted.
T * aItemPointer to the item to be inserted.

isEmpty()

boolisEmpty()const [inline]

Use STL vector Checks if there are some items in vector.

Since
S60 5.0

operator=(const AlfPtrVector &)

AlfPtrVector &operator=(const AlfPtrVector &)[private]

Parameters

const AlfPtrVector &

operator[](uint)

T *operator[](uintaPos)const [inline]

Use STL vector Returns the item at given index in the vector.

Since
S60 5.0

Parameters

uint aPosPosition from which item has been queried.

remove(uint)

boolremove(uintaPos)[inline]

Use STL vector Removes the item from vector at given position. Item will be automatically deleted if auto delete property is set to true.

Since
S60 5.0

Parameters

uint aPosPosition of the item to be removed.

resize(uint)

boolresize(uintaSize)[inline]

Use STL vector Resizes the vector to new size. Existing items in the vector will be restored if auto delete property is false.

Since
S60 5.0

Parameters

uint aSizeNew size in bytes.

setAutoDelete(bool)

voidsetAutoDelete(boolaAutoDelete = true)[inline]

Use STL vector Sets the auto delete property of vector.

Since
S60 5.0

Parameters

bool aAutoDelete = trueValue(true/false) of the property.Default value is true.

size()

uint size()const [inline]

Use STL vector Returns the size in bytes occupied by vector.

Since
S60 5.0

Member Data Documentation

bool mDelItem

boolmDelItem[private]

Auto delete

AlfPtrVectorImpl mImpl

AlfPtrVectorImpl mImpl[private]

Owned body