|
||
class CCleanup : public CBase;
Implements the cleanup stack.
An object of this type is created and used by the cleanup stack interface, CTrapCleanup
.
CBase
-
Base class for all classes to be instantiated on the heap.
CCleanup
-
Implements the cleanup stack.
Defined in CCleanup
:
CCleanup()
Default constructor. Check(TAny *)
Checks that the cleanup item at the top of the cleanup stack represents a cleanu...DoPop(TInt,TBool)
Provides an implementation for CCleanup::Pop() and CCleanup::PopAndDestroy().DoPopAll(TBool)
Provides an implementation for CCleanup::PopAll() and CCleanup::PopAndDestroyAll...New()
Creates a new cleanup stack object.NewL()
Creates a new cleanup stack object, and leaves if there is insufficient memory t...NextLevel()
Goes to the next cleanup level. Pop()
Pops a single cleanup item from the cleanup stack.Pop(TInt)
Pops the specified number of cleanup items from the cleanup stack.PopAll()
Pops all cleanup items at the current level, and then decrements the level. PopAndDestroy()
Pops a single cleanup item from the cleanup stack, and invokes its cleanup opera...PopAndDestroy(TInt)
Pops the specified number of cleanup items from the cleanup stack, and invokes t...PopAndDestroyAll()
Pops all cleanup items at the current level, invokes their cleanup operations an...PreviousLevel()
Goes to the previous cleanup level.PushL(CBase *)
Pushes a cleanup item onto the cleanup stack.PushL(TAny *)
Pushes a cleanup item onto the cleanup stack.PushL(TCleanupItem)
Pushes a cleanup item onto the cleanup stack.iBase
Pointer to the bottom of the cleanup stack.iNext
Pointer to the next availaible slot in the cleanup stack.iTop
Pointer to the top of the cleanup stack.~CCleanup()
Destructor.Inherited from CBase
:
Delete(CBase *)
Deletes the specified object.Extension_(TUint,TAny *&,TAny *)
Extension function operator new(TUint)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TAny *)
Initialises the object to binary zeroes.operator new(TUint,TLeave)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TLeave,TUint)
Allocates the object from the heap and then initialises its contents to binary z...operator new(TUint,TUint)
Allocates the object from the heap and then initialises its contents to binary z...IMPORT_C static CCleanup* NewL();
Creates a new cleanup stack object, and leaves if there is insufficient memory to create it.
The cleanup stack itself is allocated with enough space initially to hold a number of stack items.
|
IMPORT_C ~CCleanup();
Destructor.
Pops and destroys all items from the cleanup stack and then destroys the cleanup stack itself.
IMPORT_C static CCleanup* New();
Creates a new cleanup stack object.
The cleanup stack itself is allocated with enough space initially to hold a number of stack items.
|
IMPORT_C void PreviousLevel();
Goes to the previous cleanup level.
|
IMPORT_C void PushL(TAny *aPtr);
Pushes a cleanup item onto the cleanup stack.
The cleanup item represents an operation that frees the specified heap cell.
|
IMPORT_C void PushL(CBase *anObject);
Pushes a cleanup item onto the cleanup stack.
The cleanup item represents an operation that deletes the specified CBase
derived object.
|
IMPORT_C void PushL(TCleanupItem anItem);
Pushes a cleanup item onto the cleanup stack.
The cleanup item represents a call back operation that performs the required cleanup.
|
IMPORT_C void Pop();
Pops a single cleanup item from the cleanup stack.
|
IMPORT_C void Pop(TInt aCount);
Pops the specified number of cleanup items from the cleanup stack.
|
|
IMPORT_C void PopAll();
Pops all cleanup items at the current level, and then decrements the level.
IMPORT_C void PopAndDestroy();
Pops a single cleanup item from the cleanup stack, and invokes its cleanup operation.
|
IMPORT_C void PopAndDestroy(TInt aCount);
Pops the specified number of cleanup items from the cleanup stack, and invokes their cleanup operations.
|
|
IMPORT_C void PopAndDestroyAll();
Pops all cleanup items at the current level, invokes their cleanup operations and then decrements the level.
IMPORT_C void Check(TAny *aExpectedItem);
Checks that the cleanup item at the top of the cleanup stack represents a cleanup operation for the specified object.
|
protected: IMPORT_C void DoPop(TInt aCount, TBool aDestroy);
Provides an implementation for CCleanup::Pop()
and CCleanup::PopAndDestroy()
.
|
protected: IMPORT_C void DoPopAll(TBool aDestroy);
Provides an implementation for CCleanup::PopAll()
and CCleanup::PopAndDestroyAll()
.
|
protected: TCleanupStackItem * iNext;
Pointer to the next availaible slot in the cleanup stack.