- Main Page
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# OSiLParserData Class Reference

The OSiLParserData Class, used to store parser data. More...

`#include <OSiLParserData.h>`

Collaboration diagram for OSiLParserData:

[legend]
List of all members.

## Public Member Functions
| OSiLParserData ()
| the OSiLParserData class constructor
| ~OSiLParserData ()
| the OSiLParserData class destructor
## Public Attributes
void * | scanner
| scanner is used to store data in a reentrant lexer we use this to pass an OSiLParserData object to the parser
int | osillineno
| if there is a parser error, osillineno holds the line number in the OSiL file where the error occured.
int | qtermcount
| store the number of quadratic terms
bool | qtermidxOneattON
| qtermidxOneattON is true if we have found the first index of the quadratic term
bool | qtermidxTwoattON
| qtermidxTwoattON is true if we have found the second index of the quadratic term
bool | qtermidxattON
| qtermidxattON is true if we have found the row index of the of a quadratic term
bool | qtermidattON
| qtermidattON is true if we have found the id of the quadratic term
bool | qtermcoefattON
| qtermcoefattON is true if we have found the coefficient of the quadratic term
OSnLNode * | nlNodePoint
| a pointer to an OSnLNode object
OSnLNodeVariable * | nlNodeVariablePoint
| a pointer to an OSnLNode object that is a variable
OSnLNodeNumber * | nlNodeNumberPoint
| a pointer to an OSnLNode object that is a number
int | nlnodecount
| nlnodecount is the number of nl nodes in the instance
int | tmpnlcount
| tmpnlcount counts the number of nl nodes actually found, if this number differs from nlnodecount, then an exception is thrown
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 type 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< OSnLNode * > | nlNodeVec
| nlNodeVec holds a vector of pointers to OSnLNodes
std::vector< OSnLNode * > | 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< OSnLNode * > | 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< OSnLNode * > | 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< OSnLNode * > | 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< OSnLNode * > | 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
bool | timeDomainStages
| store the type of <timeDomain> (extend as needed)
bool | timeDomainInterval
int | stagecount
| store the number of stages
bool | stagenameON
| stagenameON is true if the current stage was given a name
std::string | stagename
| store the name of the current stage
bool | stageVariablesON
| for each stage we need to track whether the <variables>, <constraints>, <objectives> elements are present.
bool | stageConstraintsON
bool | stageObjectivesON
bool | stageVariablesOrdered
bool | stageConstraintsOrdered
bool | stageObjectivesOrdered
int | stageVariableStartIdx
int | stageConstraintStartIdx
int | stageObjectiveStartIdx
int | stagevarcount
int | stageconcount
int | stageobjcount
int | nvarcovered
| these two integers track how many variables and constraints have been assigned to a stage; this is used for consistency checks.
int | nconcovered
int * | m_miVarStageInfo
| m_miVarStageInfo is an array that for each variable gives the stage to which it belongs.
int * | m_miConStageInfo
| m_miConStageInfo is an array that for each constraint gives the stage to which it belongs.
int * | m_miObjStageInfo
| m_miObjStageInfo is an array that for each objective gives the stage to which it belongs.
bool | intervalhorizonON
| intervalhorizonON is true if we have found a horizon for the time interval
double | intervalhorizon
| intervalhorizon holds the value of the end of the planning horizon
bool | intervalstartON
| intervalstartON is true if we have found a start time for the time interval
double | intervalstart
| intervalstart holds the value for the start of the planning horizon

## Detailed Description

The OSiLParserData Class, used to store parser data.

Author:
  Robert Fourer, Jun Ma, Kipp Martin

Version:
  1.0, 03/14/2004

Since:
  OS 1.0

Remarks:
  The OSiLParserData class is used to hold the nonlinear part of the problem when an OSiL instance is parsed. We do this so we can have a reentrant parser. We do not have to store the linear part because we do not use flex/bison to parse the linear part of the problem.

Definition at line 34 of file OSiLParserData.h.

## Constructor & Destructor Documentation

OSiLParserData::OSiLParserData | ( |  | ) |

the OSiLParserData class constructor

Definition at line 41 of file OSiLParserData.cpp.

References m_miConStageInfo, m_miObjStageInfo, and m_miVarStageInfo.

OSiLParserData::~OSiLParserData | ( |  | ) |

the OSiLParserData class destructor

Definition at line 19 of file OSiLParserData.cpp.

References allDiffVec, m_miConStageInfo, m_miObjStageInfo, m_miVarStageInfo, maxVec, minVec, nlNodeVec, productVec, and sumVec.

## Member Data Documentation

void* OSiLParserData::scanner

scanner is used to store data in a reentrant lexer we use this to pass an OSiLParserData object to the parser

Definition at line 44 of file OSiLParserData.h.

Referenced by OSiLReader::OSiLReader(), and OSiLReader::~OSiLReader().

int OSiLParserData::osillineno

if there is a parser error, osillineno holds the line number in the OSiL file where the error occured.

Definition at line 49 of file OSiLParserData.h.

int OSiLParserData::qtermcount

store the number of quadratic terms

Definition at line 54 of file OSiLParserData.h.

bool OSiLParserData::qtermidxOneattON

qtermidxOneattON is true if we have found the first index of the quadratic term

Definition at line 58 of file OSiLParserData.h.

bool OSiLParserData::qtermidxTwoattON

qtermidxTwoattON is true if we have found the second index of the quadratic term

Definition at line 62 of file OSiLParserData.h.

bool OSiLParserData::qtermidxattON

qtermidxattON is true if we have found the row index of the of a quadratic term

Definition at line 66 of file OSiLParserData.h.

bool OSiLParserData::qtermidattON

qtermidattON is true if we have found the id of the quadratic term

Definition at line 69 of file OSiLParserData.h.

bool OSiLParserData::qtermcoefattON

qtermcoefattON is true if we have found the coefficient of the quadratic term

Definition at line 74 of file OSiLParserData.h.

OSnLNode* OSiLParserData::nlNodePoint

a pointer to an OSnLNode object

Definition at line 79 of file OSiLParserData.h.

OSnLNodeVariable* OSiLParserData::nlNodeVariablePoint

a pointer to an OSnLNode object that is a variable

Definition at line 82 of file OSiLParserData.h.

OSnLNodeNumber* OSiLParserData::nlNodeNumberPoint

a pointer to an OSnLNode object that is a number

Definition at line 85 of file OSiLParserData.h.

int OSiLParserData::nlnodecount

nlnodecount is the number of nl nodes in the instance

Definition at line 88 of file OSiLParserData.h.

int OSiLParserData::tmpnlcount

tmpnlcount counts the number of nl nodes actually found, if this number differs from nlnodecount, then an exception is thrown

Definition at line 93 of file OSiLParserData.h.

bool OSiLParserData::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 type attribute

Definition at line 99 of file OSiLParserData.h.

bool OSiLParserData::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 105 of file OSiLParserData.h.

bool OSiLParserData::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 111 of file OSiLParserData.h.

bool OSiLParserData::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 117 of file OSiLParserData.h.

bool OSiLParserData::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 123 of file OSiLParserData.h.

std::vector<OSnLNode*> OSiLParserData::nlNodeVec

nlNodeVec holds a vector of pointers to OSnLNodes

Definition at line 126 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

std::vector<OSnLNode*> OSiLParserData::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 132 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

std::vector<OSnLNode*> OSiLParserData::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 138 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

std::vector<OSnLNode*> OSiLParserData::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 144 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

std::vector<OSnLNode*> OSiLParserData::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 150 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

std::vector<OSnLNode*> OSiLParserData::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 156 of file OSiLParserData.h.

Referenced by ~OSiLParserData().

bool OSiLParserData::timeDomainStages

store the type of <timeDomain> (extend as needed)

Definition at line 162 of file OSiLParserData.h.

bool OSiLParserData::timeDomainInterval

Definition at line 163 of file OSiLParserData.h.

int OSiLParserData::stagecount

store the number of stages

Definition at line 166 of file OSiLParserData.h.

bool OSiLParserData::stagenameON

stagenameON is true if the current stage was given a name

Definition at line 169 of file OSiLParserData.h.

std::string OSiLParserData::stagename

store the name of the current stage

Definition at line 172 of file OSiLParserData.h.

bool OSiLParserData::stageVariablesON

for each stage we need to track whether the <variables>, <constraints>, <objectives> elements are present.

..

Definition at line 176 of file OSiLParserData.h.

bool OSiLParserData::stageConstraintsON

Definition at line 177 of file OSiLParserData.h.

bool OSiLParserData::stageObjectivesON

Definition at line 178 of file OSiLParserData.h.

bool OSiLParserData::stageVariablesOrdered

..we need to track whether the variables, constraints, objectives are given in temporal order...

Definition at line 182 of file OSiLParserData.h.

bool OSiLParserData::stageConstraintsOrdered

Definition at line 183 of file OSiLParserData.h.

bool OSiLParserData::stageObjectivesOrdered

Definition at line 184 of file OSiLParserData.h.

int OSiLParserData::stageVariableStartIdx

..we need to track the first variable, constraint, objective...

Definition at line 187 of file OSiLParserData.h.

int OSiLParserData::stageConstraintStartIdx

Definition at line 188 of file OSiLParserData.h.

int OSiLParserData::stageObjectiveStartIdx

Definition at line 189 of file OSiLParserData.h.

int OSiLParserData::stagevarcount

..and we need to track the number of variables we have seen

Definition at line 192 of file OSiLParserData.h.

int OSiLParserData::stageconcount

Definition at line 193 of file OSiLParserData.h.

int OSiLParserData::stageobjcount

Definition at line 194 of file OSiLParserData.h.

int OSiLParserData::nvarcovered

these two integers track how many variables and constraints have been assigned to a stage; this is used for consistency checks.

Definition at line 198 of file OSiLParserData.h.

int OSiLParserData::nconcovered

Definition at line 199 of file OSiLParserData.h.

int* OSiLParserData::m_miVarStageInfo

m_miVarStageInfo is an array that for each variable gives the stage to which it belongs.

Definition at line 204 of file OSiLParserData.h.

Referenced by OSiLParserData(), and ~OSiLParserData().

int* OSiLParserData::m_miConStageInfo

m_miConStageInfo is an array that for each constraint gives the stage to which it belongs.

Definition at line 209 of file OSiLParserData.h.

Referenced by OSiLParserData(), and ~OSiLParserData().

int* OSiLParserData::m_miObjStageInfo

m_miObjStageInfo is an array that for each objective gives the stage to which it belongs.

Definition at line 214 of file OSiLParserData.h.

Referenced by OSiLParserData(), and ~OSiLParserData().

bool OSiLParserData::intervalhorizonON

intervalhorizonON is true if we have found a horizon for the time interval

Definition at line 218 of file OSiLParserData.h.

double OSiLParserData::intervalhorizon

intervalhorizon holds the value of the end of the planning horizon

Definition at line 221 of file OSiLParserData.h.

bool OSiLParserData::intervalstartON

intervalstartON is true if we have found a start time for the time interval

Definition at line 225 of file OSiLParserData.h.

double OSiLParserData::intervalstart

intervalstart holds the value for the start of the planning horizon

Definition at line 228 of file OSiLParserData.h.

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

- /home/coin/SVN-release/OS-2.3.5/OS/src/OSParsers/OSiLParserData.h
- /home/coin/SVN-release/OS-2.3.5/OS/src/OSParsers/OSiLParserData.cpp