![]() |
|
Manages low-level value type functionality used within execution. More...
#include <executionTypeRegistry.h>
Public Member Functions | |
| VdfExecutionTypeRegistry (const VdfExecutionTypeRegistry &)=delete | |
| VdfExecutionTypeRegistry & | operator= (const VdfExecutionTypeRegistry &)=delete |
| template<typename T > | |
| const T & | GetFallback () const |
Returns the registered fallback value for T from the registry. | |
Static Public Member Functions | |
| static VDF_API VdfExecutionTypeRegistry & | GetInstance () |
| Returns the VdfExecutionTypeRegistry singleton instance. | |
| template<typename T > | |
| static TfType | Define (const T &fallback) |
Registers T with execution's runtime type dispatch system. | |
| template<typename T , typename B > | |
| static TfType | Define (const T &fallback) |
Registers T with execution's runtime type dispatch system as a derived type of B. | |
| template<typename T > | |
| static TfType | CheckForRegistration () |
Checks if T is defined as an execution value type. | |
| static VDF_API TfType | CheckForRegistration (const std::type_info &typeInfo) |
Checks if ti is defined as an execution value type. | |
| static VDF_API VdfVector | CreateEmptyVector (TfType type) |
| Create an empty VdfVector holding empty data of the given TfType. | |
| static VDF_API void | FillVector (TfType type, size_t numElements, VdfVector *vector) |
Fills vector with the fallback value registered for the given type. | |
Friends | |
| class | TfSingleton< VdfExecutionTypeRegistry > |
Manages low-level value type functionality used within execution.
All types used as values in execution must be registered with VdfExecutionTypeRegistry::Define.
All API is thread safe.
Definition at line 37 of file executionTypeRegistry.h.
|
inlinestatic |
Checks if T is defined as an execution value type.
Returns the TfType of T. If the check fails, a fatal error will be issued. The intent is to make sure that all required types are registered at the time this method is called.
Definition at line 87 of file executionTypeRegistry.h.
|
static |
Checks if ti is defined as an execution value type.
This method will issue a fatal error if the type isn't registered.
Create an empty VdfVector holding empty data of the given TfType.
Note this creates an empty vector, not a fallback-valued vector. See also VdfTypedVector for creating empty vectors by type.
|
static |
Registers T with execution's runtime type dispatch system.
fallback is required because execution supports types that are not default constructible as well as types for which a default-constructed value is not the desired fallback value.
This call will also define T with TfType if it is not registered yet.
Definition at line 210 of file executionTypeRegistry.h.
|
static |
Registers T with execution's runtime type dispatch system as a derived type of B.
Definition at line 229 of file executionTypeRegistry.h.
Fills vector with the fallback value registered for the given type.
|
inline |
Returns the registered fallback value for T from the registry.
It is a fatal error to query types that are not registered.
Definition at line 270 of file executionTypeRegistry.h.
|
static |
Returns the VdfExecutionTypeRegistry singleton instance.
|
friend |
Definition at line 109 of file executionTypeRegistry.h.