|
neic-glass3
1.4.6
|
glass3::util::BaseClass class - encapsulates the most basic setup and configuration logic. More...
#include <baseclass.h>


Public Member Functions | |
| BaseClass () | |
| BaseClass constructor. More... | |
| virtual | ~BaseClass () |
| BaseClass destructor. More... | |
| virtual bool | setup (std::shared_ptr< const json::Object > config) |
| BaseClass configuration function. More... | |
| virtual void | clear () |
| BaseClass clear function. More... | |
| const std::shared_ptr< const json::Object > | getConfig () |
| bool | getSetup () |
| Retrieves the class member boolean flag indicating whether the class has been setup, set to true if setup was successful. More... | |
| const std::string & | getDefaultAgencyId () |
| Function to retrieve the name of the default agency id. More... | |
| void | setDefaultAgencyId (const std::string &id) |
| Function to set the name of the default agency id. More... | |
| const std::string & | getDefaultAuthor () |
| Function to retrieve the name of the default author. More... | |
| void | setDefaultAuthor (const std::string &author) |
| Function to set the name of the default author. More... | |
Protected Attributes | |
| std::shared_ptr< const json::Object > | m_Config |
| A shared pointer to the json::Object that holds the configuration. More... | |
| std::atomic< bool > | m_bIsSetup |
| the boolean flag indicating whether the class has been setup, set to true if setup was successful. More... | |
| std::string | m_DefaultAgencyID |
| A std::string containing the default agency id to use in parsing if one is not provided. More... | |
| std::string | m_DefaultAuthor |
| A std::string containing the default author to use in parsing if one is not provided. More... | |
glass3::util::BaseClass class - encapsulates the most basic setup and configuration logic.
Class encapsulating the setup and configuration logic, which is common to most neic-glass3 classes outside of glasscore. The BaseClass is a simple, almost abstract class that provides setup and clear interfaces and keeps a pointer to the current configuration. The class also provides a mutex for thread safety
This class is intended to be extended by derived classes.
| glass3::util::BaseClass::BaseClass | ( | ) |
|
virtual |
|
virtual |
BaseClass clear function.
The clear function for the BaseClass class. Clears all configuration.
Reimplemented in glasscore::CHypoList, glasscore::CWeb, glass3::input::Input, glass3::output::output, glasscore::CPickList, glass3::process::Associator, glass3::fileInput, glass3::fileOutput, glass3::brokerOutput, glass3::brokerInput, glasscore::CSiteList, glass3::util::Cache, and glass3::util::Queue.
| const std::shared_ptr< const json::Object > glass3::util::BaseClass::getConfig | ( | ) |
| const std::string & glass3::util::BaseClass::getDefaultAgencyId | ( | ) |
Function to retrieve the name of the default agency id.
This function retrieves the name of default agency id, this name is used by many of the derived classes
| const std::string & glass3::util::BaseClass::getDefaultAuthor | ( | ) |
Function to retrieve the name of the default author.
This function retrieves the name of the default author, this name is used by many of the derived classes
| bool glass3::util::BaseClass::getSetup | ( | ) |
Retrieves the class member boolean flag indicating whether the class has been setup, set to true if setup was successful.
| void glass3::util::BaseClass::setDefaultAgencyId | ( | const std::string & | id | ) |
Function to set the name of the default agency id.
This function sets the name of the default agency id, this name is used by many of the derived classes
| id | = A std::string containing the default agency id to set |
| void glass3::util::BaseClass::setDefaultAuthor | ( | const std::string & | author | ) |
Function to set the name of the default author.
This function sets the name of the default author, this name is used by many of the derived classes
| author | = A std::string containing the default author to set |
|
virtual |
BaseClass configuration function.
The this function configures the BaseClass class
| config | - A shared_ptr to a json::Object containing to the configuration to use |
Reimplemented in glass3::input::Input, glass3::output::output, glass3::process::Associator, glass3::fileInput, glass3::fileOutput, glass3::brokerOutput, and glass3::brokerInput.
|
protected |
the boolean flag indicating whether the class has been setup, set to true if setup was successful.
|
protected |
A shared pointer to the json::Object that holds the configuration.
|
protected |
A std::string containing the default agency id to use in parsing if one is not provided.
|
protected |
A std::string containing the default author to use in parsing if one is not provided.
1.8.11