My Project
OSnLParserData Class Reference

The OSnLParserData Class. More...

#include <OSnLParserData.h>

Public Member Functions

 OSnLParserData ()
 the OSnLParserData class constructor
 
 ~OSnLParserData ()
 the OSnLParserData class destructor
 

Public Attributes

bool categoryAttributePresent
 generic attributes
 
std::string categoryAttribute
 
bool typeAttributePresent
 
std::string typeAttribute
 
bool varTypeAttributePresent
 
std::string varTypeAttribute
 
bool objTypeAttributePresent
 
std::string objTypeAttribute
 
bool conTypeAttributePresent
 
std::string conTypeAttribute
 
bool enumTypeAttributePresent
 
std::string enumTypeAttribute
 
bool nameAttributePresent
 
std::string nameAttribute
 
bool valueAttributePresent
 
std::string valueAttribute
 
bool lbValueAttributePresent
 
std::string lbValueAttribute
 
bool ubValueAttributePresent
 
std::string ubValueAttribute
 
bool descriptionAttributePresent
 
std::string descriptionAttribute
 
bool solverAttributePresent
 
std::string solverAttribute
 
bool unitAttributePresent
 
std::string unitAttribute
 
bool idxAttributePresent
 
int idxAttribute
 
bool shapeAttributePresent
 
int tempInt
 some temporary items to facilitate code sharing
 
int numberOf
 
int kounter
 
int iOther
 
int iOption
 
double tempVal
 
std::string tempStr
 
ExprNodenlNodePoint
 These entities are used for parsing <nonlinearExpressions>

 
OSnLNodeVariablenlNodeVariablePoint
 a pointer to an OSnLNode object that is a variable
 
OSnLNodeNumbernlNodeNumberPoint
 a pointer to an OSnLNode object that is a number
 
OSnLMNodeMatrixReferencenlMNodeMatrixRef
 a pointer to an OSnLMNode object that is a simple matrix reference
 
OSnLMNodeMatrixVarnlMNodeMatrixVar
 a pointer to an OSnLMNode object that is a matrixVar reference
 
OSnLMNodeMatrixObjnlMNodeMatrixObj
 a pointer to an OSnLMNode object that is a matrixObj reference
 
OSnLMNodeMatrixConnlMNodeMatrixCon
 a pointer to an OSnLMNode object that is a matrixCon reference
 
int nlnodenumber
 nlnodenumber is the number of nl nodes in the instance
 
int tmpnlcount
 tmpnlcount counts the number of nl nodes actually found.
 
bool numbertypeattON
 numbertypeattON is set to true if the type attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one number attribute
 
bool numbervalueattON
 numbervalueattON is set to true if the value attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one value attribute
 
bool numberidattON
 numberidattON is set to true if the id attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one id attribute
 
bool variableidxattON
 variableidxattON is set to true if the idx attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one idx attribute
 
bool variablecoefattON
 variablecoefattON is set to true if the coeff attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one coeff attribute
 
std::vector< ExprNode * > nlNodeVec
 nlNodeVec holds a vector of pointers to OSnLNodes and OSnLMNodes In order to build the expression tree correctly from the prefix notation found in the OSiL file, we need to store both OSnLNodes and OSnLMNodes into the same vector of ExprNodes
 
std::vector< ExprNode * > sumVec
 the OSnLNodeSum node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > allDiffVec
 the OSnLNodeallDiff node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > productVec
 the OSnLNodeProduct node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > maxVec
 the OSnLNodeMax node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > minVec
 the OSnLNodeMin node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > matrixSumVec
 the OSnLMNodeMatrixSum node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
std::vector< ExprNode * > matrixProductVec
 the OSnLMNodeProduct node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children
 
bool matrixreftypeattON
 matrixreftypeattON is set to true if the type attribute has been parsed for an OSnLMNodeMatrixReference object, an exception is thrown if there is more than one matrixref attribute
 
bool matrixidxattON
 matrixidxattON is set to true if the idx attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one idx attribute
 
bool includeDiagonalAttributePresent
 Attributes and other data items associated with parsing the OSnLMNodes.
 
bool includeDiagonalAttribute
 
char * errorText
 if the parser finds invalid text it is held here and we delete if the file was not valid
 
std::string parser_errors
 used to accumulate error message so the parser does not die on the first error encountered
 
bool ignoreDataAfterErrors
 two booleans to govern the behavior after an error has been encountered
 
bool suppressFurtherErrorMessages
 

Detailed Description

The OSnLParserData Class.

Remarks
The OSnLParserData class is used to temporarily hold data found in parsing the OSnL schema elements. We do this so we can have a reentrant parser.

Definition at line 29 of file OSnLParserData.h.

Constructor & Destructor Documentation

◆ OSnLParserData()

OSnLParserData::OSnLParserData ( )

the OSnLParserData class constructor

Definition at line 24 of file OSnLParserData.cpp.

◆ ~OSnLParserData()

OSnLParserData::~OSnLParserData ( )

the OSnLParserData class destructor

Definition at line 19 of file OSnLParserData.cpp.

Member Data Documentation

◆ categoryAttributePresent

bool OSnLParserData::categoryAttributePresent

generic attributes

Definition at line 34 of file OSnLParserData.h.

◆ categoryAttribute

std::string OSnLParserData::categoryAttribute

Definition at line 35 of file OSnLParserData.h.

◆ typeAttributePresent

bool OSnLParserData::typeAttributePresent

Definition at line 36 of file OSnLParserData.h.

◆ typeAttribute

std::string OSnLParserData::typeAttribute

Definition at line 37 of file OSnLParserData.h.

◆ varTypeAttributePresent

bool OSnLParserData::varTypeAttributePresent

Definition at line 38 of file OSnLParserData.h.

◆ varTypeAttribute

std::string OSnLParserData::varTypeAttribute

Definition at line 39 of file OSnLParserData.h.

◆ objTypeAttributePresent

bool OSnLParserData::objTypeAttributePresent

Definition at line 40 of file OSnLParserData.h.

◆ objTypeAttribute

std::string OSnLParserData::objTypeAttribute

Definition at line 41 of file OSnLParserData.h.

◆ conTypeAttributePresent

bool OSnLParserData::conTypeAttributePresent

Definition at line 42 of file OSnLParserData.h.

◆ conTypeAttribute

std::string OSnLParserData::conTypeAttribute

Definition at line 43 of file OSnLParserData.h.

◆ enumTypeAttributePresent

bool OSnLParserData::enumTypeAttributePresent

Definition at line 44 of file OSnLParserData.h.

◆ enumTypeAttribute

std::string OSnLParserData::enumTypeAttribute

Definition at line 45 of file OSnLParserData.h.

◆ nameAttributePresent

bool OSnLParserData::nameAttributePresent

Definition at line 46 of file OSnLParserData.h.

◆ nameAttribute

std::string OSnLParserData::nameAttribute

Definition at line 47 of file OSnLParserData.h.

◆ valueAttributePresent

bool OSnLParserData::valueAttributePresent

Definition at line 48 of file OSnLParserData.h.

◆ valueAttribute

std::string OSnLParserData::valueAttribute

Definition at line 49 of file OSnLParserData.h.

◆ lbValueAttributePresent

bool OSnLParserData::lbValueAttributePresent

Definition at line 50 of file OSnLParserData.h.

◆ lbValueAttribute

std::string OSnLParserData::lbValueAttribute

Definition at line 51 of file OSnLParserData.h.

◆ ubValueAttributePresent

bool OSnLParserData::ubValueAttributePresent

Definition at line 52 of file OSnLParserData.h.

◆ ubValueAttribute

std::string OSnLParserData::ubValueAttribute

Definition at line 53 of file OSnLParserData.h.

◆ descriptionAttributePresent

bool OSnLParserData::descriptionAttributePresent

Definition at line 54 of file OSnLParserData.h.

◆ descriptionAttribute

std::string OSnLParserData::descriptionAttribute

Definition at line 55 of file OSnLParserData.h.

◆ solverAttributePresent

bool OSnLParserData::solverAttributePresent

Definition at line 56 of file OSnLParserData.h.

◆ solverAttribute

std::string OSnLParserData::solverAttribute

Definition at line 57 of file OSnLParserData.h.

◆ unitAttributePresent

bool OSnLParserData::unitAttributePresent

Definition at line 58 of file OSnLParserData.h.

◆ unitAttribute

std::string OSnLParserData::unitAttribute

Definition at line 59 of file OSnLParserData.h.

◆ idxAttributePresent

bool OSnLParserData::idxAttributePresent

Definition at line 60 of file OSnLParserData.h.

◆ idxAttribute

int OSnLParserData::idxAttribute

Definition at line 61 of file OSnLParserData.h.

◆ shapeAttributePresent

bool OSnLParserData::shapeAttributePresent

Definition at line 62 of file OSnLParserData.h.

◆ tempInt

int OSnLParserData::tempInt

some temporary items to facilitate code sharing

Definition at line 65 of file OSnLParserData.h.

◆ numberOf

int OSnLParserData::numberOf

Definition at line 66 of file OSnLParserData.h.

◆ kounter

int OSnLParserData::kounter

Definition at line 67 of file OSnLParserData.h.

◆ iOther

int OSnLParserData::iOther

Definition at line 68 of file OSnLParserData.h.

◆ iOption

int OSnLParserData::iOption

Definition at line 69 of file OSnLParserData.h.

◆ tempVal

double OSnLParserData::tempVal

Definition at line 70 of file OSnLParserData.h.

◆ tempStr

std::string OSnLParserData::tempStr

Definition at line 71 of file OSnLParserData.h.

◆ nlNodePoint

ExprNode* OSnLParserData::nlNodePoint

These entities are used for parsing <nonlinearExpressions>

a pointer to an OSnLNode object

Definition at line 83 of file OSnLParserData.h.

◆ nlNodeVariablePoint

OSnLNodeVariable* OSnLParserData::nlNodeVariablePoint

a pointer to an OSnLNode object that is a variable

Definition at line 86 of file OSnLParserData.h.

◆ nlNodeNumberPoint

OSnLNodeNumber* OSnLParserData::nlNodeNumberPoint

a pointer to an OSnLNode object that is a number

Definition at line 89 of file OSnLParserData.h.

◆ nlMNodeMatrixRef

OSnLMNodeMatrixReference* OSnLParserData::nlMNodeMatrixRef

a pointer to an OSnLMNode object that is a simple matrix reference

Definition at line 92 of file OSnLParserData.h.

◆ nlMNodeMatrixVar

OSnLMNodeMatrixVar* OSnLParserData::nlMNodeMatrixVar

a pointer to an OSnLMNode object that is a matrixVar reference

Definition at line 95 of file OSnLParserData.h.

◆ nlMNodeMatrixObj

OSnLMNodeMatrixObj* OSnLParserData::nlMNodeMatrixObj

a pointer to an OSnLMNode object that is a matrixObj reference

Definition at line 98 of file OSnLParserData.h.

◆ nlMNodeMatrixCon

OSnLMNodeMatrixCon* OSnLParserData::nlMNodeMatrixCon

a pointer to an OSnLMNode object that is a matrixCon reference

Definition at line 101 of file OSnLParserData.h.

◆ nlnodenumber

int OSnLParserData::nlnodenumber

nlnodenumber is the number of nl nodes in the instance

Definition at line 104 of file OSnLParserData.h.

◆ tmpnlcount

int OSnLParserData::tmpnlcount

tmpnlcount counts the number of nl nodes actually found.

If this number differs from nlnodenumber, then an exception is thrown

Definition at line 109 of file OSnLParserData.h.

◆ numbertypeattON

bool OSnLParserData::numbertypeattON

numbertypeattON is set to true if the type attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one number attribute

Definition at line 115 of file OSnLParserData.h.

◆ numbervalueattON

bool OSnLParserData::numbervalueattON

numbervalueattON is set to true if the value attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one value attribute

Definition at line 121 of file OSnLParserData.h.

◆ numberidattON

bool OSnLParserData::numberidattON

numberidattON is set to true if the id attribute has been parsed for an OSnLNodeNumber object, an exception is thrown if there is more than one id attribute

Definition at line 127 of file OSnLParserData.h.

◆ variableidxattON

bool OSnLParserData::variableidxattON

variableidxattON is set to true if the idx attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one idx attribute

Definition at line 133 of file OSnLParserData.h.

◆ variablecoefattON

bool OSnLParserData::variablecoefattON

variablecoefattON is set to true if the coeff attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one coeff attribute

Definition at line 139 of file OSnLParserData.h.

◆ nlNodeVec

std::vector<ExprNode*> OSnLParserData::nlNodeVec

nlNodeVec holds a vector of pointers to OSnLNodes and OSnLMNodes In order to build the expression tree correctly from the prefix notation found in the OSiL file, we need to store both OSnLNodes and OSnLMNodes into the same vector of ExprNodes

Definition at line 146 of file OSnLParserData.h.

◆ sumVec

std::vector<ExprNode*> OSnLParserData::sumVec

the OSnLNodeSum node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 152 of file OSnLParserData.h.

◆ allDiffVec

std::vector<ExprNode*> OSnLParserData::allDiffVec

the OSnLNodeallDiff node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 158 of file OSnLParserData.h.

◆ productVec

std::vector<ExprNode*> OSnLParserData::productVec

the OSnLNodeProduct node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 164 of file OSnLParserData.h.

◆ maxVec

std::vector<ExprNode*> OSnLParserData::maxVec

the OSnLNodeMax node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 170 of file OSnLParserData.h.

◆ minVec

std::vector<ExprNode*> OSnLParserData::minVec

the OSnLNodeMin node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 176 of file OSnLParserData.h.

◆ matrixSumVec

std::vector<ExprNode*> OSnLParserData::matrixSumVec

the OSnLMNodeMatrixSum node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 182 of file OSnLParserData.h.

◆ matrixProductVec

std::vector<ExprNode*> OSnLParserData::matrixProductVec

the OSnLMNodeProduct node can have any number of children, including other children with an indeterminate number of children so when parsing we need to temporarily store all of its children

Definition at line 188 of file OSnLParserData.h.

◆ matrixreftypeattON

bool OSnLParserData::matrixreftypeattON

matrixreftypeattON is set to true if the type attribute has been parsed for an OSnLMNodeMatrixReference object, an exception is thrown if there is more than one matrixref attribute

Definition at line 194 of file OSnLParserData.h.

◆ matrixidxattON

bool OSnLParserData::matrixidxattON

matrixidxattON is set to true if the idx attribute has been parsed for an OSnLNodeVariable, an exception is thrown if there is more than one idx attribute

Definition at line 200 of file OSnLParserData.h.

◆ includeDiagonalAttributePresent

bool OSnLParserData::includeDiagonalAttributePresent

Attributes and other data items associated with parsing the OSnLMNodes.

Definition at line 203 of file OSnLParserData.h.

◆ includeDiagonalAttribute

bool OSnLParserData::includeDiagonalAttribute

Definition at line 204 of file OSnLParserData.h.

◆ errorText

char* OSnLParserData::errorText

if the parser finds invalid text it is held here and we delete if the file was not valid

Definition at line 209 of file OSnLParserData.h.

◆ parser_errors

std::string OSnLParserData::parser_errors

used to accumulate error message so the parser does not die on the first error encountered

Definition at line 214 of file OSnLParserData.h.

◆ ignoreDataAfterErrors

bool OSnLParserData::ignoreDataAfterErrors

two booleans to govern the behavior after an error has been encountered

Definition at line 217 of file OSnLParserData.h.

◆ suppressFurtherErrorMessages

bool OSnLParserData::suppressFurtherErrorMessages

Definition at line 218 of file OSnLParserData.h.


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