ORIGINAL
|
Base class for deleters defining the deletion policy interface. More...
#include <deleter.h>
Public Types | |
template<typename T > | |
using | rebound_deleter = DERIVED< T > |
Rebound deleter type for type transformation scenarios. | |
Public Member Functions | |
constexpr | deleterBase () noexcept=default |
Default constructor. | |
virtual | ~deleterBase ()=0 |
Pure virtual destructor. | |
virtual void | operator() (const TYPE *ptr) const noexcept=0 |
Deletion operator. | |
Base class for deleters defining the deletion policy interface.
Base class for array deleters.
TYPE | Type of the resource. |
DERIVED | CRTP Derived deleter type. |
This class serves as the base for all specific deleters and provides a pure virtual function operator()
to handle resource deletion. Since this is an abstract class, it cannot be instantiated directly.
TYPE[] | Element type of the array. |
DERIVED | CRTP Derived deleter type. |
A specialization of deleterBase
designed specifically for deleting arrays. Provides the interface for array-specific deletion policies.
Rebound deleter type for type transformation scenarios.
T | New type for the rebound deleter |
|
constexprdefaultnoexcept |
Default constructor.
The constexpr specifier allows compile-time constant initialization.
|
pure virtualdefault |
Pure virtual destructor.
Must be implemented by derived classes to ensure proper cleanup.
|
pure virtualnoexcept |
Deletion operator.
ptr | Pointer to the object to delete. |
This method must be implemented by derived classes to free the resource pointed to by ptr
.
Implemented in original::deleter< TYPE >, and original::deleter< TYPE[]>.