Class Loader
Defined in File data_loader.hpp
Derived Types
public morpheus::FileDataLoader
(Class FileDataLoader)public morpheus::GRPCDataLoader
(Class GRPCDataLoader)public morpheus::LambdaLoader
(Class LambdaLoader)public morpheus::PayloadDataLoader
(Class PayloadDataLoader)public morpheus::RESTDataLoader
(Class RESTDataLoader)
-
class Loader
Abstract class for loading data from a source.
This class defines two virtual methods for loading and returning control messages, as well as a protected method for accessing the configuration information. It can be extended to implement specific loading logic for different types of data sources.
Subclassed by morpheus::FileDataLoader, morpheus::GRPCDataLoader, morpheus::LambdaLoader, morpheus::PayloadDataLoader, morpheus::RESTDataLoader
Public Functions
- ~Loader() = default
Destructor for the Loader class.
- Loader() = default
Default constructor for the Loader class.
-
Loader(nlohmann::json config)
Constructor for the Loader class.
- Parameters
config – A json object containing configuration information for the loader.
Virtual method for extracting message payload from a control message.
- Parameters
- Returns
message – A shared pointer to the control message containing the payload.
A shared pointer to the message payload as a MessageMeta object.
Virtual method for loading a control message.
- Parameters
message – A shared pointer to the control message to be loaded.
task – A json object describing the loading task.
- Returns
A shared pointer to the loaded control message.
Protected Functions
-
nlohmann::json config() const
Protected method for accessing the loader’s configuration information.
- Returns
A json object containing configuration information for the loader.