OS  2.9.3
OSnLParserData.h
Go to the documentation of this file.
1 /* $Id: OSnLParserData.h 4806 2014-06-07 11:37:46Z Gassmann $ */
14 #ifndef OSNLPARSERDATA_H
15 #define OSNLPARSERDATA_H
16 
17 #include "OSnLNode.h"
18 #include <vector>
19 
20 
30 {
31 public:
32 
35  std::string categoryAttribute;
37  std::string typeAttribute;
39  std::string varTypeAttribute;
41  std::string objTypeAttribute;
43  std::string conTypeAttribute;
45  std::string enumTypeAttribute;
47  std::string nameAttribute;
49  std::string valueAttribute;
51  std::string lbValueAttribute;
53  std::string ubValueAttribute;
55  std::string descriptionAttribute;
57  std::string solverAttribute;
59  std::string unitAttribute;
63 
65  int tempInt;
66  int numberOf;
67  int kounter;
68  int iOther;
69  int iOption;
70  double tempVal;
71  std::string tempStr;
72 
74  OSnLParserData( );
75 
77  ~OSnLParserData() ;
78 
79 
84 
87 
90 
93 
96 
101 
107 
113 
119 
125 
131 
137  std::vector<ExprNode*> nlNodeVec;
138 
143  std::vector<ExprNode*> sumVec;
144 
149  std::vector<ExprNode*> allDiffVec;
150 
155  std::vector<ExprNode*> productVec;
156 
161  std::vector<ExprNode*> maxVec;
162 
167  std::vector<ExprNode*> minVec;
168 
173  std::vector<ExprNode*> matrixSumVec;
174 
179  std::vector<ExprNode*> matrixProductVec;
180 
186 
192 
196 
200  char *errorText;
201 
205  std::string parser_errors;
206 
210 };//OSnLParserData
211 
212 
213 inline void osnl_empty_vectors( OSnLParserData* osnlData)
214 {
215 
216 }//end osnl_empty_vectors
217 
218 
219 
220 #endif /*OSNLPARSERDATA_H_*/
std::vector< ExprNode * > nlNodeVec
nlNodeVec holds a vector of pointers to OSnLNodes and OSnLMNodes In order to build the expression tre...
std::string nameAttribute
std::vector< ExprNode * > sumVec
the OSnLNodeSum node can have any number of children, including other children with an indeterminate ...
int nlnodenumber
nlnodenumber is the number of nl nodes in the instance
std::string ubValueAttribute
bool includeDiagonalAttribute
std::vector< ExprNode * > productVec
the OSnLNodeProduct node can have any number of children, including other children with an indetermin...
bool numbervalueattON
numbervalueattON is set to true if the value attribute has been parsed for an OSnLNodeNumber object...
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
OSnLParserData()
the OSnLParserData class constructor
std::vector< ExprNode * > maxVec
the OSnLNodeMax node can have any number of children, including other children with an indeterminate ...
bool categoryAttributePresent
generic attributes
The OSnLNodeVariable Class.
Definition: OSnLNode.h:1494
bool numbertypeattON
numbertypeattON is set to true if the type attribute has been parsed for an OSnLNodeNumber object...
std::string parser_errors
used to accumulate error message so the parser does not die on the first error encountered ...
bool idxAttributePresent
std::string conTypeAttribute
std::string descriptionAttribute
std::string typeAttribute
char * errorText
if the parser finds invalid text it is held here and we delete if the file was not valid ...
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 descriptionAttributePresent
bool shapeAttributePresent
std::string unitAttribute
OSnLMNodeMatrixReference * nlMNodeMatrixRef
a pointer to an OSnLMNode object that is a simple matrix reference
std::string objTypeAttribute
bool suppressFurtherErrorMessages
OSnLNodeVariable * nlNodeVariablePoint
a pointer to an OSnLNode object that is a variable
bool ubValueAttributePresent
bool includeDiagonalAttributePresent
Attributes and other data items associated with parsing the OSnLMNodes.
bool objTypeAttributePresent
std::vector< ExprNode * > minVec
the OSnLNodeMin node can have any number of children, including other children with an indeterminate ...
bool ignoreDataAfterErrors
two booleans to govern the behavior after an error has been encountered
int tmpnlcount
tmpnlcount counts the number of nl nodes actually found.
void osnl_empty_vectors(OSnLParserData *osnlData)
std::string solverAttribute
bool enumTypeAttributePresent
bool conTypeAttributePresent
bool matrixreftypeattON
matrixreftypeattON is set to true if the type attribute has been parsed for an OSnLMNodeMatrixReferen...
std::string lbValueAttribute
bool valueAttributePresent
bool typeAttributePresent
bool numberidattON
numberidattON is set to true if the id attribute has been parsed for an OSnLNodeNumber object...
The OSnLNodeNumber Class.
Definition: OSnLNode.h:1288
bool solverAttributePresent
The OSnLParserData Class.
A generic class from which we derive both OSnLNode and OSnLMNode.
Definition: OSnLNode.h:56
std::string categoryAttribute
bool unitAttributePresent
This file defines the OSnLNode class along with its derived classes.
int tempInt
some temporary items to facilitate code sharing
std::string enumTypeAttribute
std::string valueAttribute
std::vector< ExprNode * > matrixSumVec
the OSnLMNodeMatrixSum node can have any number of children, including other children with an indeter...
std::vector< ExprNode * > allDiffVec
the OSnLNodeallDiff node can have any number of children, including other children with an indetermin...
ExprNode * nlNodePoint
These entities are used for parsing
bool varTypeAttributePresent
OSnLNodeNumber * nlNodeNumberPoint
a pointer to an OSnLNode object that is a number
std::string varTypeAttribute
bool lbValueAttributePresent
bool nameAttributePresent
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 * > matrixProductVec
the OSnLMNodeProduct node can have any number of children, including other children with an indetermi...
~OSnLParserData()
the OSnLParserData class destructor
std::string tempStr