OSrLParserData.h
Go to the documentation of this file.
1 
15 #ifndef OSRLPARSERDATA_H
16 #define OSRLPARSERDATA_H
17 
18 #include "OSnLNode.h"
19 #include <vector>
20 #include <sstream>
21 
22 
23 
32  std::string name;
33 
37  std::string description;
38 
42  std::string value;
43 
47  int numberOfVar;
48 
55  std::string *otherVarText;
56 
57 
64  int *otherVarIndex;
65 
66 };
67 
68 
81 class OSrLParserData{
82 public:
83 
85  OSrLParserData( );
86 
87  //** the OSrLParserData class destructor */
88  ~OSrLParserData() ;
89 
90 
92  std::string statusType;
93 
95  std::string statusDescription;
96 
99  double timeValue;
100  std::string timeType;
101  std::string timeCategory;
102  std::string timeUnit;
103  std::string timeDescription;
104 
107  int numberOfTimes;
108 
110  std::string tmpOtherValue;
111  std::string tmpOtherName;
112  std::string tmpOtherDescription;
113 
116  void* scanner;
117 
120 
122  int numberOfVariables;
123 
126 
128  int numberOfObjectives;
129 
131  int kounter;
132 
134  int iOther;
135 
137  int ivar;
138 
140  double tempVal;
141 
143  std::ostringstream outStr;
144 
149 
152 
157 
162 
167 
172 
176  double **objectiveValues;
177 
179  double **primalSolution;
180 
182  double **dualSolution;
183 
184 
185 
186 
189 
191  std::vector<OtherVariableResultStruct*> otherVarVec;
192 
196  char *errorText;
197 };
198 
199 #endif /*OSRLPARSERDATA_H_*/
int numberOfOtherVariableResults
the number of types of variable results other than the value of the variable
std::string value
value holds the text of the value attribute of the OtherVariableResult element
This file defines the OSnLNode class along with its derived classes.
int numberOfConstraints
total number of constraints in the model instance
bool generalStatusTypePresent
set generalStatusTypePresent to true if there is a general status attribute parsed ...
std::vector< OtherVariableResultStruct * > otherVarVec
store a vector of pointers to otherVarVec structures
std::string timeUnit
int iOther
a temporary counter to count other variable, objective and constraint results
double timeValue
the next few variables store a time measurement and associated attribute values
std::string tmpOtherValue
Provide temporary storage for attribute values associated with an OtherVarResult. ...
OSrLParserData()
the OSrLParserData class constructor
int numberOfObjectives
total number of Objectives in the model instance
std::string statusType
the status type of the result
std::string name
name holds the text of the name attribute of the OtherVariableResult element
int * objectiveIdx
pointer to the array of objective function indexes in each solution
std::ostringstream outStr
a temporary variable to hold an output stream value
std::string tmpOtherDescription
std::string description
description holds the text of the description attribute of the OtherVariableResult element ...
bool otherNamePresent
set otherNamePresent to true if there is a name attribute in anotherVarResult
char * errorText
if the parser finds invalid text it is held here and we delete if the file was not valid ...
int numberOfTimes
There could be more than one time measurement; numberOfTimes stores the number of them...
int * otherVarIndex
otherVarIndex is a pointer to an array with number of elements equal to the number of variables...
int numberOfSolutions
number of result solutions
std::string timeDescription
void * scanner
scanner is used to store data in a reentrant lexer we use this to pass an OSrLParserData object to th...
double ** objectiveValues
for each solution we have a pointer to the value of each objective function
std::string timeCategory
std::string tmpOtherName
int ivar
a temporary counter to count second-level objects
int solutionIdx
and index on which solution we have found
std::string * otherVarText
otherVarText is a pointer to an array with number of elements equal to the number of variables...
bool statusTypePresent
set statusTypePresent to true if there is a status attribute parsed
int kounter
a temporary counter to count variables, number of attributes, etc.
A structure to information about an OtherVariableResult element.
std::string timeType
int numberOfVariables
total number of variables in the model instance
struct OtherVariableResultStruct * otherVarStruct
a pointer to an OtherVariableResultStruct structure
double tempVal
a temporary variable to hold an integer or double value
The OSrLParserData Class.
int numberOfVar
numberOfVar holds the number of variables in the array of the OtherVariableResult element ...
double ** dualSolution
for each solution we have a pointer to each dual solution
double ** primalSolution
for each solution we have a pointer to each primal solution
std::string statusDescription
the status Description of the solution