Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Microsoft
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Microsoft/COMPointer.h |
| Include | #include "Microsoft/COMPointer.h" |
Syntax
template<typename T>
class TComPtr
Remarks
Smart COM object pointer.
Constructors
| Type | Name | Description | |
|---|---|---|---|
TComPtr () |
Default constructor (initialized to null). | ||
TComPtr
(
PointerType*const Object |
Create and initialize a new instance. | ||
TComPtr
(
const TComPtr< PointerType >& Other |
Copy constructor. | ||
TComPtr
(
TComPtr< PointerType >&& Other |
Move constructor. |
Destructors
| Type | Name | Description | |
|---|---|---|---|
~TComPtr () |
Destructor. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Attach
(
PointerType* Object |
Set the pointer without adding a reference. | |
| void | Detach () |
Reset the pointer without releasing a reference. | |
| HRESULT | FromQueryInterface
(
REFIID Riid, |
Initialize this pointer from a COM interface to be queried. | |
| PointerType * | Get () |
Get raw pointer to the object pointed to. | |
| const bool | IsValid () |
Whether this pointer is pointing to an actual object. | |
| void | Reset () |
Reset this pointer to null. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| bool | operator!=
(
PointerType*const Object |
||
| PointerType ** | operator& () |
||
| TComPtr< PointerType > & | operator=
(
TComPtr< PointerType >&& Other |
Move assignment operator. | |
| TComPtr< PointerType > & | operator=
(
const TComPtr< PointerType >& Other |
Copy assignment operator. | |
| TComPtr< PointerType > & | operator=
(
PointerType*const Object |
Assignment operator. | |
| bool | operator==
(
PointerType*const Object |
||
| PointerType * | operator-> () |
Typedefs
| Name | Description |
|---|---|
| PointerType |