SST 15.0
Structural Simulation Toolkit
|
Implements a constructor for a derived base as usually happens with subcomponents, e.g. More...
#include <elementbuilder.h>
Public Types | |
template<class __NewCtor> | |
using | ExtendCtor = ExtendedCtor<__NewCtor, ExtendedCtor<NewCtor, OldCtor>> |
template<class NewBase> | |
using | ChangeBase = typename NewCtor::template ChangeBase<NewBase> |
Static Public Member Functions | |
template<class T> | |
static std::enable_if_t< OldCtor::template is_constructible_v< T >, bool > | add () |
The derived Ctor can "block" the more abstract Ctor, meaning an object should only be instantiated as the most derived type. | |
template<class T> | |
static std::enable_if_t<!OldCtor::template is_constructible_v< T >, bool > | add () |
Static Public Attributes | |
template<class T> | |
static constexpr bool | is_constructible_v = NewCtor::template is_constructible_v<T> |
Implements a constructor for a derived base as usually happens with subcomponents, e.g.
class U extends API extends Subcomponent. You can construct U as either an API* or a Subcomponent* depending on usage.
|
inlinestatic |
The derived Ctor can "block" the more abstract Ctor, meaning an object should only be instantiated as the most derived type.
enable_if here checks if both the derived API and the parent API are still valid
Referenced by SST::ELI::ExtendedCtor< __NewCtor, ExtendedCtor< NewCtor, OldCtor > >::add().