|
RMM API 2.0.0
|
Factory class for creating and registering frontend objects. More...
#include <FrontEndFactory.h>
Static Public Member Functions | |
| template<typename T, typename... Args> | |
| static std::shared_ptr< T > | createAndRegister (RMMAPI *pRmmAPI, int ring, int node, std::string name, Args &&... args) |
| Creates and registers a frontend object. | |
Factory class for creating and registering frontend objects.
This class provides a templated static method to create instances of frontend objects that inherit from FrontEndBase and automatically register them in the RMMAPI topology.
|
inlinestatic |
Creates and registers a frontend object.
This method creates a new instance of a frontend object of type T, registers it in the topology of the RMMAPI, and returns a shared pointer to it. The frontend object must inherit from FrontEndBase and implement the configFE method.
| T | The type of the frontend object to create. Must be derived from FrontEndBase. |
| Args | Variadic template parameters for additional constructor arguments. |
| [in] | pRmmAPI | Pointer to the RMMAPI instance that manages the topology. |
| [in] | ring | The ring ID where the frontend is located. |
| [in] | node | The node ID within the ring. |
| [in] | name | The name of the frontend device. |
| [in] | addrMap | A mapping of register names to their addresses. |
| [in] | args | Additional arguments passed to the constructor of T. |