COPASI API
4.40.278
|
#include <ParameterGroupHandler.h>
Public Member Functions | |
ParameterGroupHandler (CXMLParser &parser, CXMLParserData &data) | |
void | setDerivedElement (const XML_Char *pszName, CCopasiParameterGroup *pDerivedElement) |
virtual | ~ParameterGroupHandler () |
Public Member Functions inherited from CXMLHandler | |
CXMLHandler (CXMLParser &parser, CXMLParserData &data, const Type &type) | |
virtual void | end (const XML_Char *pszName) |
virtual void | start (const XML_Char *pszName, const XML_Char **papszAttrs) |
virtual | ~CXMLHandler () |
Protected Member Functions | |
virtual sProcessLogic * | getProcessLogic () const |
virtual bool | processEnd (const XML_Char *pszName) |
virtual CXMLHandler * | processStart (const XML_Char *pszName, const XML_Char **papszAttrs) |
Protected Member Functions inherited from CXMLHandler | |
void | addFix (const std::string &key, CDataObject *pObject) |
std::string | getElementName (const Type &type) const |
std::string | getExpectedElements (const Type &type) const |
CXMLHandler * | getHandler (const Type &type) |
void | init () |
Private Member Functions | |
bool | isUniqueParameter () const |
ParameterGroupHandler () | |
Private Attributes | |
std::string | mDerivedElement |
std::map< std::string, std::set< std::string > > | mNonUniqueParameters |
std::stack< CCopasiParameterGroup * > | mParameterGroupStack |
|
private |
ParameterGroupHandler::ParameterGroupHandler | ( | CXMLParser & | parser, |
CXMLParserData & | data | ||
) |
Constructor
CXMLParser | & parser |
CXMLParserData | & data |
Replace ParameterGroup with the name type of the handler and implement the three methods below.
References CXMLHandler::init(), and mNonUniqueParameters.
|
virtual |
Destructor
|
protectedvirtual |
Retrieve the structure containing the process logic for the handler.
Implements CXMLHandler.
References CXMLHandler::AFTER, CXMLHandler::BEFORE, CXMLHandler::HANDLER_COUNT, CXMLHandler::Parameter, CXMLHandler::ParameterGroup, and CXMLHandler::ParameterText.
|
private |
References CDataObject::getObjectName(), mNonUniqueParameters, mParameterGroupStack, CXMLHandler::mpData, and CXMLParserData::pCurrentParameter.
Referenced by processEnd().
|
protectedvirtual |
Process the end of an element
const | XML_Char *pszName |
Implements CXMLHandler.
References CCopasiMessage::EXCEPTION, CExpatTemplate< CType >::getCurrentColumnNumber(), CExpatTemplate< CType >::getCurrentLineNumber(), CCopasiParameter::getKey(), CDataObject::getObjectName(), CCopasiParameter::getType(), CCopasiTask::getType(), isUniqueParameter(), CCopasiParameter::KEY, CXMLHandler::mCurrentElement, MCXML, mDerivedElement, CXMLHandler::mElementName2Type, CXMLHandler::mLevel, mParameterGroupStack, CXMLHandler::mpData, CXMLHandler::mpParser, CXMLHandler::Parameter, CTaskEnum::parameterFitting, CXMLHandler::ParameterGroup, CXMLHandler::ParameterText, CXMLParserData::pCurrentParameter, CXMLParserData::pCurrentTask, pdelete, and CXMLParserData::UnmappedKeyParameters.
|
protectedvirtual |
Process the start of an element
const | XML_Char *pszName |
const | XML_Char **papszAttrs |
Implements CXMLHandler.
References CCopasiMessage::EXCEPTION, CExpatTemplate< CType >::getAttributeValue(), CExpatTemplate< CType >::getCurrentColumnNumber(), CExpatTemplate< CType >::getCurrentLineNumber(), CXMLHandler::getHandler(), CXMLHandler::mCurrentElement, MCXML, CXMLHandler::mLevel, mParameterGroupStack, CXMLHandler::mpParser, CXMLHandler::Parameter, CXMLHandler::ParameterGroup, and CXMLHandler::ParameterText.
void ParameterGroupHandler::setDerivedElement | ( | const XML_Char * | pszName, |
CCopasiParameterGroup * | pDerivedElement | ||
) |
Set the derived element for which the handler is called such as methods and problems
const | XML_Char * pszName, |
CCopasiParameterGroup | * pDerivedElement |
References mDerivedElement, CXMLHandler::mElementName2Type, CXMLHandler::mLevel, mParameterGroupStack, and CXMLHandler::ParameterGroup.
|
private |
A flag indicating whether the current element is derived from a parameter group.
Referenced by processEnd(), and setDerivedElement().
|
private |
A map listing parameters for which the uniqueness is not enforced
Referenced by isUniqueParameter(), and ParameterGroupHandler().
|
private |
A stack of groups which contains the hierarchy of currently processed groups.
Referenced by isUniqueParameter(), processEnd(), processStart(), and setDerivedElement().