OtherOptionEnumeration Class Reference

#include <OSGeneral.h>

Inheritance diagram for OtherOptionEnumeration:

Inheritance graph
[legend]
Collaboration diagram for OtherOptionEnumeration:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 OtherOptionEnumeration ()
 ~OtherOptionEnumeration ()
 OtherOptionEnumeration (int n)
bool IsEqual (OtherOptionEnumeration *that)
 A function to check for the equality of two objects.
bool setRandom (double density, bool conformant, int iMin, int iMax)
 A function to make a random instance of this class.
bool setOtherOptionEnumeration (std::string value, std::string description, int *i, int ni)
 Set the indices for a particular level in an enumeration.
std::string getValue ()
 Get the value for a particular level in an enumeration.
std::string getDescription ()
 Get the description for a particular level in an enumeration.

Public Attributes

std::string value
std::string description

Detailed Description

brief an integer vector data structure used in OSOption and OSResult

This class extends IntVector by adding two string-valued elements, value and description

Definition at line 479 of file OSGeneral.h.


Constructor & Destructor Documentation

OtherOptionEnumeration::OtherOptionEnumeration (  ) 

Definition at line 504 of file OSGeneral.cpp.

OtherOptionEnumeration::~OtherOptionEnumeration (  ) 

Definition at line 524 of file OSGeneral.cpp.

OtherOptionEnumeration::OtherOptionEnumeration ( int  n  ) 

Definition at line 514 of file OSGeneral.cpp.


Member Function Documentation

bool OtherOptionEnumeration::IsEqual ( OtherOptionEnumeration that  ) 

A function to check for the equality of two objects.

Definition at line 550 of file OSGeneral.cpp.

References description, IntVector::IsEqual(), and value.

bool OtherOptionEnumeration::setRandom ( double  density,
bool  conformant,
int  iMin,
int  iMax 
)

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" attributes and <XXX> children)
iMin,: lowest value (inclusive) that an entry in this vector can take
iMax,: greatest value (inclusive) that an entry in this vector can take

Reimplemented from IntVector.

Definition at line 592 of file OSGeneral.cpp.

References description, OSRand(), IntVector::setRandom(), and value.

Referenced by OtherConstraintResult::setRandom(), OtherObjectiveResult::setRandom(), OtherVariableResult::setRandom(), OtherConstraintOption::setRandom(), OtherObjectiveOption::setRandom(), and OtherVariableOption::setRandom().

bool OtherOptionEnumeration::setOtherOptionEnumeration ( std::string  value,
std::string  description,
int *  i,
int  ni 
)

Set the indices for a particular level in an enumeration.

Parameters:
value represents the value of this enumeration member
description holds additional information about this value
i contains the array of indices
ni contains the number of elements in i

Definition at line 531 of file OSGeneral.cpp.

References IntVector::setIntVector().

Referenced by ConstraintOption::setOther(), ObjectiveOption::setOther(), VariableOption::setOther(), OSResult::setOtherOptionEnumeration(), and OSOption::setOtherOptionEnumeration().

std::string OtherOptionEnumeration::getValue (  ) 

Get the value for a particular level in an enumeration.

Definition at line 538 of file OSGeneral.cpp.

References value.

std::string OtherOptionEnumeration::getDescription (  ) 

Get the description for a particular level in an enumeration.

Definition at line 543 of file OSGeneral.cpp.

References description.


Member Data Documentation

std::string OtherOptionEnumeration::value

Definition at line 482 of file OSGeneral.h.

Referenced by ConstraintOption::addOther(), ObjectiveOption::addOther(), VariableOption::addOther(), OSResult::getOtherConstraintResultEnumerationValue(), OSResult::getOtherObjectiveResultEnumerationValue(), OSResult::getOtherVariableResultEnumerationValue(), getValue(), IsEqual(), and setRandom().

std::string OtherOptionEnumeration::description

Definition at line 483 of file OSGeneral.h.

Referenced by ConstraintOption::addOther(), ObjectiveOption::addOther(), VariableOption::addOther(), getDescription(), OSResult::getOtherConstraintResultEnumerationDescription(), OSResult::getOtherObjectiveResultEnumerationDescription(), OSResult::getOtherVariableResultEnumerationDescription(), IsEqual(), and setRandom().


The documentation for this class was generated from the following files:
Generated on Wed Nov 30 03:12:13 2011 by  doxygen 1.4.7