description | title | ms.date | ms.topic | f1_keywords | helpviewer_keywords | ms.assetid | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Learn more about: Module::GenericReleaseNotifier Class |
Module::GenericReleaseNotifier Class |
09/17/2018 |
reference |
|
|
244a8fbe-f89b-409b-aa65-db3e37f9b125 |
Invokes an event handler when the last object in the current module is released. The event handler is specified by on a lambda, functor, or pointer-to-function.
template<typename T>
class GenericReleaseNotifier : public ReleaseNotifier;
T
The type of the data member that contains the location of the event handler.
Name | Description |
---|---|
Module::GenericReleaseNotifier::GenericReleaseNotifier | Initializes a new instance of the Module::GenericReleaseNotifier class. |
Name | Description |
---|---|
Module::GenericReleaseNotifier::Invoke | Calls the event handler associated with the current Module::GenericReleaseNotifier object. |
Name | Description |
---|---|
Module::GenericReleaseNotifier::callback_ | Holds the lambda, functor, or pointer-to-function event handler associated with the current Module::GenericReleaseNotifier object. |
ReleaseNotifier
GenericReleaseNotifier
Header: module.h
Namespace: Microsoft::WRL
Holds the lambda, functor, or pointer-to-function event handler associated with the current Module::GenericReleaseNotifier
object.
T callback_;
Initializes a new instance of the Module::GenericReleaseNotifier
class.
GenericReleaseNotifier(
T callback,
bool release
) throw() : ReleaseNotifier(release), callback_(callback);
callback
A lambda, functor, or pointer-to-function event handler that can be invoked with the parentheses function operator (()
).
release
Specify true
to enable calling the underlying Module::ReleaseNotifier::Release() method; otherwise, specify false
.
Calls the event handler associated with the current Module::GenericReleaseNotifier
object.
void Invoke();