InterfaceTraits Structure
The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.
The latest version of this topic can be found at InterfaceTraits Structure.
Supports the WRL infrastructure and is not intended to be used directly from your code.
Syntax
template<
typename I0
>
struct __declspec(novtable) InterfaceTraits;
template<
typename CloakedType
>
struct __declspec(novtable) InterfaceTraits<CloakedIid<CloakedType>>;
template<>
struct __declspec(novtable) InterfaceTraits<Nil>;
Parameters
I0
The name of an interface.
CloakedType
For RuntimeClass, Implements and ChainInterfaces, an interface that won't be in the list of supported interface IDs.
Remarks
Implements common characteristics of an interface.
The second template is a specialization for cloaked interfaces. The third template is a specialization for Nil parameters.
Members
Public Typedefs
Name | Description |
---|---|
Base |
A synonym for the I0 template parameter. |
Public Methods
Name | Description |
---|---|
InterfaceTraits::CanCastTo Method | Indicates whether the specified pointer can be cast to a pointer to Base . |
InterfaceTraits::CastToBase Method | Casts the specified pointer to a pointer to Base . |
InterfaceTraits::CastToUnknown Method | Casts the specified pointer to a pointer to IUnknown. |
InterfaceTraits::FillArrayWithIid Method | Assigns the interface ID of Base to the array element specified by the index argument. |
InterfaceTraits::Verify Method | Verifies that Base is properly derived. |
Public Constants
Name | Description |
---|---|
InterfaceTraits::IidCount Constant | Holds the number of interface IDs associated with the current InterfaceTraits object. |
Inheritance Hierarchy
InterfaceTraits
Requirements
Header: implements.h
Namespace: Microsoft::WRL::Details