Utility class templates that provide RAII-based automatic resource management.
void | CallCleanupFunction | ( | T * | aObjPtr | ) | [inline] |
Implementation function.In order to override the default cleanup strategy for a particular type, use the provided DEFINE_CLEANUP_FUNCTION utility macro
Utility macro that can be used for defining the cleanup member function for a class (typically a R-class).
This macro can be used in the same namespace in which the R-class is defined or in a namespace in which the R-class is used.
Example:
class RDestroyableClass { public: ... void Destroy(); // member function used for cleanup and releasing the resources owned by a RDestroyableClass object ... };
DEFINE_CLEANUP_FUNCTION(RDestroyableClass, Destroy)
Utility macro that can be used for specializing the default cleanup strategy class template TResourceCleanupStrategy for a particular class (typically a R-class). The default cleanup strategy for a class specified using DEFINE_CLEANUP_STRATEGY overrides any other cleanup strategy specified using DEFINE_CLEANUP_FUNCTION for that class.
This macro must be used in the same namespace in which the R-class is defined.
Utility macro that can be used for enabling single phase construction for CBase-derived classes. This is necessary because Symbian OS currently lacks the placement delete operator counterparts corresponding to the placement new operators that take a TLeave parameter (new(ELeave)), which will result in memory leaks if a class constructor leaves.
This macro must be used within a public section of a class definition, if the single phase construction is part of the public interface of the class.
Current Limitation CONSTRUCTORS_MAY_LEAVE is an unfortunate blight on the usability of single-phase construction, but we have yet to come up with a better alternative in the face of the legacy handling of ELeave.
void | ManagedPopCleanupStackItem | ( | T | aIsManaged | ) |
Enumerator | Value | Description |
---|---|---|
EPtrNonSpecial | ||
EPtrCBaseDerived |
Enumerator | Value | Description |
---|---|---|
EAutoHandleNonSpecial | ||
EAutoRHandleBaseDerived | ||
EAutoHandleRBuf |
TBool | operator== | ( | const LManagedPtr< T > & | aPtr1, |
const LManagedPtr< U > & | aPtr2 | |||
) |
TBool | operator!= | ( | const LManagedPtr< T > & | aPtr1, |
const LManagedPtr< U > & | aPtr2 | |||
) |
TBool | operator< | ( | const LManagedPtr< T > & | aPtr1, |
const LManagedPtr< U > & | aPtr2 | |||
) |
TBool | operator== | ( | const LCleanedupPtr< T > & | aPtr1, |
const LCleanedupPtr< U > & | aPtr2 | |||
) |
TBool | operator!= | ( | const LCleanedupPtr< T > & | aPtr1, |
const LCleanedupPtr< U > & | aPtr2 | |||
) |
TBool | operator< | ( | const LCleanedupPtr< T > & | aPtr1, |
const LCleanedupPtr< U > & | aPtr2 | |||
) |