Public Member Functions | Private Attributes | List of all members
CVocOptions Class Reference

Vocabulary Options class. More...

#include <vocoptions.H>

Public Member Functions

 CVocOptions ()
 Default constructor.
int Parse (int argc, char *argv[])
 Parser function.
bool DebugMode () const
 Debug mode function.
bool StackMode () const
 Stack mode function.
bool CaseMode () const
 Case mode function.
bool SynonymMode () const
 Synonym mode function.
bool BeepMode () const
 Beep mode function This function returns the current beep mode settings.
enVocMode GetMode () const
 Get inquiry mode function.
enVocLang GetLang () const
 Get language mode function.
int GetNumOfPasses () const
 Get number of passes function.
char ** GetVocFiles () const
 Get name from vocabulary files function.
int GetNumOfVocFiles () const
 Get number of vocabulary files function.

Private Attributes

bool m_bDebug
 debug mode boolean
bool m_bStack
 stack mode boolean
bool m_bCaseMode
 case-sensitive boolean
bool m_bSynonym
 synonym boolean
bool m_bBeep
 beep boolean
enVocMode m_enMode
 mode enum.
enVocLang m_enLang
 language enum.
int m_nNumPasses
 number of passes
char ** m_pVocFiles
 null-terminated voc-file list
int m_nNumFiles
 number of vocabulary files

Detailed Description

Vocabulary Options class.

This class parses the command line and makes the options available for other classes.

Constructor & Destructor Documentation

CVocOptions::CVocOptions ( )

Default constructor.

This constructor initializes the member variables with default values.

Member Function Documentation

bool CVocOptions::BeepMode ( ) const
inline

Beep mode function This function returns the current beep mode settings.

Returns
This function returns true if the beep mode is enabled; otherwise false.

References m_bBeep.

bool CVocOptions::CaseMode ( ) const
inline

Case mode function.

This function returns the current case mode setting.

Returns
This function returns true if the mode is case-sensitive and false if case-insensitive.

References m_bCaseMode.

bool CVocOptions::DebugMode ( ) const
inline

Debug mode function.

This function returns the current debug mode setting.

Returns
This function returns true if the debug mode is enabled; otherwise false.

References m_bDebug.

enVocLang CVocOptions::GetLang ( ) const
inline

Get language mode function.

This function returns the current inquiry language setting.

Returns
This function returns vlLeft if the inquiry language is left, vlRight if right.

References m_enLang.

enVocMode CVocOptions::GetMode ( ) const
inline

Get inquiry mode function.

This function returns the current inquiry mode setting.

Returns
This function returns vmOrder if the inquiry mode is order, vmRandom if random and vmAlphabetical if alphabetical.

References m_enMode.

int CVocOptions::GetNumOfPasses ( ) const
inline

Get number of passes function.

Returns
This function returns the number of passes setting.

References m_nNumPasses.

int CVocOptions::GetNumOfVocFiles ( ) const
inline

Get number of vocabulary files function.

Returns
This function returns number of vocabulary files.
See Also
GetVocFiles()

References m_nNumFiles.

char** CVocOptions::GetVocFiles ( ) const
inline

Get name from vocabulary files function.

This function returns a array with vocabulary files.

Returns
This functions returns a null-terminated character array.
See Also
GetNumOfVocFiles()

References m_pVocFiles.

int CVocOptions::Parse ( int  argc,
char *  argv[] 
)

Parser function.

This function parses the command line and fills the member variables.

Returns
The operation was unsuccessful if the return value is unequal -1.

References CVocatraInfo::GetAlphabeticalMode(), CVocatraInfo::GetLeftLang(), CVocatraInfo::GetName(), CVocatraInfo::GetOrderMode(), CVocatraInfo::GetRandomMode(), CVocatraInfo::GetRightLang(), CVocatraInfo::PrintHelp(), CVocatraInfo::PrintUsage(), and CVocatraInfo::PrintVersion().

bool CVocOptions::StackMode ( ) const
inline

Stack mode function.

This function returns the current stack mode setting.

Returns
This function returns true if the stack mode is enabled; otherwise false.

References m_bStack.

bool CVocOptions::SynonymMode ( ) const
inline

Synonym mode function.

This function returns the current synonym mode setting.

Returns
This function returns true if the synonym mode is enabled; otherwise false.

References m_bSynonym.

Member Data Documentation

enVocLang CVocOptions::m_enLang
private

language enum.

This value will be vlLeft if the inquiry language is left; vlRight if right.

Referenced by GetLang().

enVocMode CVocOptions::m_enMode
private

mode enum.

This value will be vmOrder if the inquiry mode is order, vmRandom if random and vmAlphabetical if alphabetical.

Referenced by GetMode().


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

Get Vocatra at SourceForge.net. Fast, secure and Free Open Source software downloads Generated for Vocatra by doxygen