13 #ifndef SST_CORE_SUBCOMPONENT_H
14 #define SST_CORE_SUBCOMPONENT_H
16 #include <sst/core/warnmacros.h>
17 #include <sst/core/baseComponent.h>
18 #include <sst/core/component.h>
19 #include <sst/core/module.h>
20 #include <sst/core/eli/elementinfo.h>
36 SST_ELI_DECLARE_INFO_EXTERN(
50 virtual void init(
unsigned int UNUSED(phase))
override {}
53 virtual void setup( )
override { }
59 Component*
const parent __attribute__ ((deprecated(
"The parent data member will be removed in SST version 10.0. With the new subcomponent structure, direct access to your parent is not allowed.")));
62 SubComponent* loadSubComponent(std::string type,
Params& params) __attribute__ ((deprecated(
"This version of loadSubComponent will be removed in SST version 10.0. Please switch to new user defined API (LoadUserSubComponent(std::string, int, ARGS...)).")));
74 #define SST_ELI_REGISTER_SUBCOMPONENT(cls,lib,name,version,desc,interface) \
75 SST_ELI_REGISTER_DERIVED(SST::SubComponent,cls,lib,name,ELI_FORWARD_AS_ONE(version),desc) \
76 SST_ELI_INTERFACE_INFO(interface)
81 #define SST_ELI_REGISTER_SUBCOMPONENT_API(cls,...) \
82 SST_ELI_DECLARE_NEW_BASE(SST::SubComponent,::cls) \
83 SST_ELI_NEW_BASE_CTOR(ComponentId_t,Params&,##__VA_ARGS__)
85 #define SST_ELI_REGISTER_SUBCOMPONENT_DERIVED_API(cls,base,...) \
86 SST_ELI_DECLARE_NEW_BASE(::base,::cls) \
87 SST_ELI_NEW_BASE_CTOR(ComponentId_t,Params&,##__VA_ARGS__)
89 #define SST_ELI_REGISTER_SUBCOMPONENT_DERIVED(cls,lib,name,version,desc,interface) \
90 SST_ELI_REGISTER_DERIVED(::interface,cls,lib,name,ELI_FORWARD_AS_ONE(version),desc) \
91 SST_ELI_INTERFACE_INFO(#interface)
93 #endif // SST_CORE_SUBCOMPONENT_H
virtual void finish() override
Called after simulation completes, but before objects are destroyed.
Definition: subcomponent.h:56
Definition: portsInfo.h:30
Main component object for the simulation.
Definition: component.h:32
Definition: statsInfo.h:27
Module is a tag class used with the loadModule function.
Definition: module.h:22
Definition: paramsInfo.h:28
virtual void setup() override
Called after all components have been constructed and initialization has completed, but before simulation time has begun.
Definition: subcomponent.h:53
Main component object for the simulation.
Definition: baseComponent.h:52
Definition: subcompSlotInfo.h:28
Parameter store.
Definition: params.h:45
virtual void init(unsigned int UNUSED(phase)) override
Used during the init phase.
Definition: subcomponent.h:50
SubComponent is a class loadable through the factory which allows dynamic functionality to be added t...
Definition: subcomponent.h:30
Definition: interfaceInfo.h:7