nidas  v1.2-1520
Public Member Functions | Private Attributes | List of all members
nidas::core::ProjectConfigs Class Reference

#include <ProjectConfigs.h>

Public Member Functions

 ProjectConfigs ()
 
 ~ProjectConfigs ()
 
const ProjectConfiggetConfig (const nidas::util::UTime &begin) const throw (nidas::util::InvalidParameterException)
 
const ProjectConfiggetConfig (const std::string &name) const throw (nidas::util::InvalidParameterException)
 
const std::list< const
ProjectConfig * > & 
getConfigs () const
 
void addConfigByTime (ProjectConfig *val) throw (nidas::util::InvalidParameterException)
 Add a project configuration, inserting it in the list, which should be sorted by time. More...
 
void addConfigByName (ProjectConfig *val) throw ()
 Add a project configuration, replacing an existing configuration if the name matches, otherwise appending the configuration on the list. More...
 
void removeConfig (const ProjectConfig *val)
 
void parseXML (const std::string &xmlFileName) throw (nidas::core::XMLException, nidas::util::InvalidParameterException)
 
void writeXML (const std::string &xmlFileName) throw (nidas::core::XMLException,nidas::util::IOException)
 
void fromDOMElement (const xercesc::DOMElement *) throw (nidas::util::InvalidParameterException)
 
xercesc::DOMElement * toDOMParent (xercesc::DOMElement *parent) const throw (xercesc::DOMException)
 
xercesc::DOMElement * toDOMElement (xercesc::DOMElement *node) const throw (xercesc::DOMException)
 

Private Attributes

std::string _xmlName
 
std::list< const ProjectConfig * > _constConfigs
 
std::list< ProjectConfig * > _configs
 

Constructor & Destructor Documentation

ProjectConfigs::ProjectConfigs ( )
ProjectConfigs::~ProjectConfigs ( )

References _configs.

Member Function Documentation

void ProjectConfigs::addConfigByName ( ProjectConfig val)
throw (
)

Add a project configuration, replacing an existing configuration if the name matches, otherwise appending the configuration on the list.

References nidas::core::ProjectConfig::getName().

void ProjectConfigs::addConfigByTime ( ProjectConfig val)
throw (nidas::util::InvalidParameterException
)

Add a project configuration, inserting it in the list, which should be sorted by time.

If the beginning time is equal to the beginning time of an existing project configuration, and the end time is prior to or equal to the beginning time of the next configuration, the existing configuration is replaced. Exceptions are thrown if project configuration times are overlapping.

References nidas::core::ProjectConfig::getBeginTime(), and nidas::core::ProjectConfig::getEndTime().

Referenced by ProjConfigIO::addConfigByTime(), and ProjConfigIO::termConfig().

void ProjectConfigs::fromDOMElement ( const xercesc::DOMElement *  node)
throw (nidas::util::InvalidParameterException
)
const ProjectConfig * ProjectConfigs::getConfig ( const nidas::util::UTime begin) const
throw (nidas::util::InvalidParameterException
)
const ProjectConfig * ProjectConfigs::getConfig ( const std::string &  name) const
throw (nidas::util::InvalidParameterException
)
const std::list< const ProjectConfig * > & ProjectConfigs::getConfigs ( ) const
void ProjectConfigs::parseXML ( const std::string &  xmlFileName)
throw (nidas::core::XMLException,
nidas::util::InvalidParameterException
)
void ProjectConfigs::removeConfig ( const ProjectConfig val)

References _configs, and _constConfigs.

Referenced by ProjConfigIO::termConfig().

xercesc::DOMElement * ProjectConfigs::toDOMElement ( xercesc::DOMElement *  node) const
throw (xercesc::DOMException
)
xercesc::DOMElement * ProjectConfigs::toDOMParent ( xercesc::DOMElement *  parent) const
throw (xercesc::DOMException
)
void ProjectConfigs::writeXML ( const std::string &  xmlFileName)
throw (nidas::core::XMLException,
nidas::util::IOException
)

Member Data Documentation

std::list<ProjectConfig*> nidas::core::ProjectConfigs::_configs
private

Referenced by removeConfig(), and ~ProjectConfigs().

std::list<const ProjectConfig*> nidas::core::ProjectConfigs::_constConfigs
private

Referenced by getConfigs(), and removeConfig().

std::string nidas::core::ProjectConfigs::_xmlName
private

The documentation for this class was generated from the following files: