Quick Links:

bal | bbl | bdl | bsl

Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes

baljsn::EncoderTestChoiceWithAllCategoriesChoice Class Reference

#include <baljsn_encoder_testtypes.h>

List of all members.

Public Types

enum  { SELECTION_ID_UNDEFINED = -1, SELECTION_ID_SELECTION0 = 0 }
enum  { NUM_SELECTIONS = 1 }
enum  { SELECTION_INDEX_SELECTION0 = 0 }

Public Member Functions

 EncoderTestChoiceWithAllCategoriesChoice ()
 EncoderTestChoiceWithAllCategoriesChoice (const EncoderTestChoiceWithAllCategoriesChoice &original)
 ~EncoderTestChoiceWithAllCategoriesChoice ()
EncoderTestChoiceWithAllCategoriesChoiceoperator= (const EncoderTestChoiceWithAllCategoriesChoice &rhs)
void reset ()
int makeSelection (int selectionId)
int makeSelection (const char *name, int nameLength)
int & makeSelection0 ()
int & makeSelection0 (int value)
template<class MANIPULATOR >
int manipulateSelection (MANIPULATOR &manipulator)
int & selection0 ()
bsl::ostream & print (bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
int selectionId () const
template<class ACCESSOR >
int accessSelection (ACCESSOR &accessor) const
const int & selection0 () const
bool isSelection0Value () const
bool isUndefinedValue () const
const char * selectionName () const

Static Public Member Functions

static const bdlat_SelectionInfolookupSelectionInfo (int id)
static const bdlat_SelectionInfolookupSelectionInfo (const char *name, int nameLength)

Static Public Attributes

static const char CLASS_NAME []
static const bdlat_SelectionInfo SELECTION_INFO_ARRAY []

Member Enumeration Documentation

anonymous enum
Enumerator:
SELECTION_ID_UNDEFINED 
SELECTION_ID_SELECTION0 
anonymous enum
Enumerator:
NUM_SELECTIONS 
anonymous enum
Enumerator:
SELECTION_INDEX_SELECTION0 

Constructor & Destructor Documentation

baljsn::EncoderTestChoiceWithAllCategoriesChoice::EncoderTestChoiceWithAllCategoriesChoice (  ) 

Create an object of type EncoderTestChoiceWithAllCategoriesChoice having the default value.

baljsn::EncoderTestChoiceWithAllCategoriesChoice::EncoderTestChoiceWithAllCategoriesChoice ( const EncoderTestChoiceWithAllCategoriesChoice original  ) 

Create an object of type EncoderTestChoiceWithAllCategoriesChoice having the value of the specified original object.

baljsn::EncoderTestChoiceWithAllCategoriesChoice::~EncoderTestChoiceWithAllCategoriesChoice (  ) 

Destroy this object.


Member Function Documentation

static const bdlat_SelectionInfo* baljsn::EncoderTestChoiceWithAllCategoriesChoice::lookupSelectionInfo ( int  id  )  [static]

Return selection information for the selection indicated by the specified id if the selection exists, and 0 otherwise.

static const bdlat_SelectionInfo* baljsn::EncoderTestChoiceWithAllCategoriesChoice::lookupSelectionInfo ( const char *  name,
int  nameLength 
) [static]

Return selection information for the selection indicated by the specified name of the specified nameLength if the selection exists, and 0 otherwise.

EncoderTestChoiceWithAllCategoriesChoice& baljsn::EncoderTestChoiceWithAllCategoriesChoice::operator= ( const EncoderTestChoiceWithAllCategoriesChoice rhs  ) 

Assign to this object the value of the specified rhs object.

void baljsn::EncoderTestChoiceWithAllCategoriesChoice::reset (  ) 

Reset this object to the default value (i.e., its value upon default construction).

int baljsn::EncoderTestChoiceWithAllCategoriesChoice::makeSelection ( int  selectionId  ) 

Set the value of this object to be the default for the selection indicated by the specified selectionId. Return 0 on success, and non-zero value otherwise (i.e., the selection is not found).

int baljsn::EncoderTestChoiceWithAllCategoriesChoice::makeSelection ( const char *  name,
int  nameLength 
)

Set the value of this object to be the default for the selection indicated by the specified name of the specified nameLength. Return 0 on success, and non-zero value otherwise (i.e., the selection is not found).

int& baljsn::EncoderTestChoiceWithAllCategoriesChoice::makeSelection0 (  ) 
int& baljsn::EncoderTestChoiceWithAllCategoriesChoice::makeSelection0 ( int  value  ) 

Set the value of this object to be a "Selection0" value. Optionally specify the value of the "Selection0". If value is not specified, the default "Selection0" value is used.

template<class MANIPULATOR >
int baljsn::EncoderTestChoiceWithAllCategoriesChoice::manipulateSelection ( MANIPULATOR &  manipulator  ) 

Invoke the specified manipulator on the address of the modifiable selection, supplying manipulator with the corresponding selection information structure. Return the value returned from the invocation of manipulator if this object has a defined selection, and -1 otherwise.

int& baljsn::EncoderTestChoiceWithAllCategoriesChoice::selection0 (  ) 

Return a reference to the modifiable "Selection0" selection of this object if "Selection0" is the current selection. The behavior is undefined unless "Selection0" is the selection of this object.

bsl::ostream& baljsn::EncoderTestChoiceWithAllCategoriesChoice::print ( bsl::ostream &  stream,
int  level = 0,
int  spacesPerLevel = 4 
) const

Format this object to the specified output stream at the optionally specified indentation level and return a reference to the modifiable stream. If level is specified, optionally specify spacesPerLevel, the number of spaces per indentation level for this and all of its nested objects. Each line is indented by the absolute value of level * spacesPerLevel. If level is negative, suppress indentation of the first line. If spacesPerLevel is negative, suppress line breaks and format the entire output on one line. If stream is initially invalid, this operation has no effect. Note that a trailing newline is provided in multiline mode only.

int baljsn::EncoderTestChoiceWithAllCategoriesChoice::selectionId (  )  const

Return the id of the current selection if the selection is defined, and -1 otherwise.

template<class ACCESSOR >
int baljsn::EncoderTestChoiceWithAllCategoriesChoice::accessSelection ( ACCESSOR &  accessor  )  const

Invoke the specified accessor on the non-modifiable selection, supplying accessor with the corresponding selection information structure. Return the value returned from the invocation of accessor if this object has a defined selection, and -1 otherwise.

const int& baljsn::EncoderTestChoiceWithAllCategoriesChoice::selection0 (  )  const

Return a reference to the non-modifiable "Selection0" selection of this object if "Selection0" is the current selection. The behavior is undefined unless "Selection0" is the selection of this object.

bool baljsn::EncoderTestChoiceWithAllCategoriesChoice::isSelection0Value (  )  const

Return true if the value of this object is a "Selection0" value, and return false otherwise.

bool baljsn::EncoderTestChoiceWithAllCategoriesChoice::isUndefinedValue (  )  const

Return true if the value of this object is undefined, and false otherwise.

const char* baljsn::EncoderTestChoiceWithAllCategoriesChoice::selectionName (  )  const

Return the symbolic name of the current selection of this object.


Member Data Documentation


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