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

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

# VariableOption Class Reference

the VariableOption class. More...

`#include <OSOption.h>`

Collaboration diagram for VariableOption:

[legend]
List of all members.

## Public Member Functions
| VariableOption ()
| Default constructor.
| ~VariableOption ()
| Class destructor.
bool | IsEqual (VariableOption *that)
| A function to check for the equality of two objects.
bool | setRandom (double density, bool conformant)
| A function to make a random instance of this class.
bool | setOther (int numberOfOptions, OtherVariableOption **other)
| A function to set an array of <other> elements.
bool | addOther (OtherVariableOption *other)
| A function to add an <other> element.
## Public Attributes
int | numberOfOtherVariableOptions
| number of <other> child elements
InitVariableValues * | initialVariableValues
| initial values for the variables
InitVariableValuesString * | initialVariableValuesString
| initial values for string-valued variables
BasisStatus * | initialBasisStatus
| initial basis information
IntegerVariableBranchingWeights * | integerVariableBranchingWeights
| branching weights for integer variables
SOSVariableBranchingWeights * | sosVariableBranchingWeights
| branching weights for SOS variables and groups
OtherVariableOption ** | other
| other variable options

## Detailed Description

the VariableOption class.

Author:
  Robert Fourer, Gus Gassmann, Jun Ma, Kipp Martin

Version:
  1.0, 21/07/2008

Since:
  OS 1.1

Remarks:
  A data structure class that corresponds to an xml element in the OSoL schema.

Definition at line 1805 of file OSOption.h.

## Constructor & Destructor Documentation

VariableOption::VariableOption | ( |  | ) |

Default constructor.

Definition at line 716 of file OSOption.cpp.

References initialBasisStatus, initialVariableValues, initialVariableValuesString, integerVariableBranchingWeights, other, and sosVariableBranchingWeights.

VariableOption::~VariableOption | ( |  | ) |

Class destructor.

Definition at line 730 of file OSOption.cpp.

References initialBasisStatus, initialVariableValues, initialVariableValuesString, integerVariableBranchingWeights, numberOfOtherVariableOptions, other, and sosVariableBranchingWeights.

## Member Function Documentation

bool VariableOption::IsEqual | ( | VariableOption * | that | ) |

A function to check for the equality of two objects.

Definition at line 8901 of file OSOption.cpp.

References initialBasisStatus, initialVariableValues, initialVariableValuesString, integerVariableBranchingWeights, numberOfOtherVariableOptions, other, and sosVariableBranchingWeights.

bool VariableOption::setRandom | ( | double | density,
|  | bool | conformant |
| ) |  |  |

A function to make a random instance of this class.

Parameters:

  | density,: | corresponds to the probability that a particular child element is created
  | conformant,: | if true enforces side constraints not enforceable in the schema (e.g., agreement of "numberOfXXX" atrbutes and <XXX> children)

Definition at line 10622 of file OSOption.cpp.

References initialBasisStatus, initialVariableValues, initialVariableValuesString, integerVariableBranchingWeights, numberOfOtherVariableOptions, OSRand(), other, OtherVariableOption::setRandom(), SOSVariableBranchingWeights::setRandom(), IntegerVariableBranchingWeights::setRandom(), BasisStatus::setRandom(), InitVariableValuesString::setRandom(), InitVariableValues::setRandom(), and sosVariableBranchingWeights.

Referenced by OptimizationOption::setRandom().

bool VariableOption::setOther | ( | int | numberOfOptions,
|  | OtherVariableOption ** | other |
| ) |  |  |

A function to set an array of <other> elements.

Parameters:

  | numberOfOptions,: | number of <other> elements to be set
  | other,: | the array of <other> elements that are to be set

Definition at line 5119 of file OSOption.cpp.

References OtherVariableOption::category, OtherVariableOption::description, OtherVariableOption::enumeration, OtherVariableOption::name, OtherVariableOption::numberOfEnumerations, numberOfOtherVariableOptions, OtherVariableOption::numberOfVar, other, OtherOptionEnumeration::setOtherOptionEnumeration(), OtherVariableOption::solver, OtherVariableOption::type, OtherVariableOption::value, and OtherVariableOption::var.

Referenced by OSOption::setOtherVariableOptions().

bool VariableOption::addOther | ( | OtherVariableOption * | other | ) |

A function to add an <other> element.

Parameters:

  | other,: | the content of the <other> element to be added

Definition at line 5184 of file OSOption.cpp.

References OtherVariableOption::category, OtherOptionEnumeration::description, OtherVariableOption::description, IntVector::el, OtherVariableOption::enumeration, OtherVariableOption::name, IntVector::numberOfEl, OtherVariableOption::numberOfEnumerations, numberOfOtherVariableOptions, OtherVariableOption::numberOfVar, other, OtherVariableOption::solver, OtherVariableOption::type, OtherOptionEnumeration::value, OtherVariableOption::value, and OtherVariableOption::var.

Referenced by OSOption::setAnOtherVariableOption().

## Member Data Documentation

int VariableOption::numberOfOtherVariableOptions

number of <other> child elements

Definition at line 1809 of file OSOption.h.

Referenced by addOther(), OSOption::getNumberOfOtherVariableOptions(), IsEqual(), OSOption::setNumberOfOtherVariableOptions(), setOther(), OSOption::setOtherOptionEnumeration(), OSOption::setOtherVariableOptionAttributes(), OSOption::setOtherVariableOptions(), OSOption::setOtherVariableOptionVar(), setRandom(), and ~VariableOption().

InitVariableValues* VariableOption::initialVariableValues

initial values for the variables

Definition at line 1812 of file OSOption.h.

Referenced by OSOption::getInitVarValuesSparse(), OSOption::getNumberOfInitVarValues(), IsEqual(), OSOption::setAnotherInitVarValue(), OSOption::setInitVarValues(), OSOption::setInitVarValuesDense(), OSOption::setInitVarValuesSparse(), setRandom(), VariableOption(), and ~VariableOption().

InitVariableValuesString* VariableOption::initialVariableValuesString

initial values for string-valued variables

Definition at line 1815 of file OSOption.h.

Referenced by OSOption::getInitVarValuesStringSparse(), OSOption::getNumberOfInitVarValuesString(), IsEqual(), OSOption::setAnotherInitVarValueString(), OSOption::setInitVarValuesString(), OSOption::setInitVarValuesStringDense(), OSOption::setInitVarValuesStringSparse(), setRandom(), VariableOption(), and ~VariableOption().

BasisStatus* VariableOption::initialBasisStatus

initial basis information

Definition at line 1818 of file OSOption.h.

Referenced by OSOption::getInitialBasisElements(), OSOption::getNumberOfInitialBasisElements(), OSOption::getVariableInitialBasisStatusDense(), IsEqual(), OSOption::setAnotherInitBasisStatus(), OSOption::setInitBasisStatus(), setRandom(), VariableOption(), and ~VariableOption().

IntegerVariableBranchingWeights* VariableOption::integerVariableBranchingWeights

branching weights for integer variables

Definition at line 1821 of file OSOption.h.

Referenced by OSOption::getIntegerVariableBranchingWeightsSparse(), OSOption::getNumberOfIntegerVariableBranchingWeights(), IsEqual(), OSOption::setAnotherIntegerVariableBranchingWeight(), OSOption::setIntegerVariableBranchingWeights(), OSOption::setIntegerVariableBranchingWeightsDense(), OSOption::setIntegerVariableBranchingWeightsSparse(), setRandom(), VariableOption(), and ~VariableOption().

SOSVariableBranchingWeights* VariableOption::sosVariableBranchingWeights

branching weights for SOS variables and groups

Definition at line 1824 of file OSOption.h.

Referenced by OSOption::getNumberOfSOS(), OSOption::getNumberOfSOSVarBranchingWeights(), OSOption::getSOSVariableBranchingWeightsSparse(), IsEqual(), OSOption::setAnotherSOSVariableBranchingWeight(), setRandom(), OSOption::setSOSVariableBranchingWeights(), VariableOption(), and ~VariableOption().

OtherVariableOption** VariableOption::other

other variable options

Definition at line 1827 of file OSOption.h.

Referenced by addOther(), OSOption::getAllOtherVariableOptions(), IsEqual(), OSOption::setNumberOfOtherVariableOptions(), setOther(), OSOption::setOtherOptionEnumeration(), OSOption::setOtherVariableOptionAttributes(), OSOption::setOtherVariableOptionVar(), setRandom(), VariableOption(), and ~VariableOption().

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

- /home/coin/SVN-release/OS-2.3.5/OS/src/OSCommonInterfaces/OSOption.h
- /home/coin/SVN-release/OS-2.3.5/OS/src/OSCommonInterfaces/OSOption.cpp