Main Page   Modules   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages   Examples  

CCmdInfo Class Reference

List of all members.

Public Methods

 CCmdInfo (int, char **, char='-')
virtual int GetSize (void) const
virtual CCmdInfoLabelEnum GetValue (int) const
std::string GetModuleFileName () const
std::string GetModulePath () const
std::string GetModuleName () const
std::string GetLineOfParameters () const

Friends

std::ostream & operator<< (std::ostream &,const CCmdInfo &)

Detailed Description

Wrappes the command line of the application.


Constructor & Destructor Documentation

CCmdInfo::CCmdInfo int   Argc,
char **   Argv,
char   LabelKey = '-'
 

Parameters:
Argc   Integer specifying how many arguments are passed to the program from the command line. Because the program name is considered an argument, the integer is at least 1. Transmitted via the main function.
Argv   Array of null-terminated strings. The first string ( Argv[0] ) is the program name, and each following string is an argument passed to the program from the command line. The last pointer ( Argv[Argc] ) is NULL.
LabelKey   Character which indicates the starting point of a label.


Member Function Documentation

std::string CCmdInfo::GetLineOfParameters   const
 

Returns:
The parameters formated in a string. The program name is omitted, use GetModuleFileName to obtain the program name.

std::string CCmdInfo::GetModuleFileName   const
 

Returns:
The full path of the program. Equivalent to Argv[0].

std::string CCmdInfo::GetModuleName   const
 

Returns:
The program name, the program path is omitted.

std::string CCmdInfo::GetModulePath   const
 

Returns:
The program path, the program name is omitted.

int CCmdInfo::GetSize void   const [virtual]
 

Gets the number of labels found in the command line.

Reimplemented from CCmdInfoData.

CCmdInfoLabelEnum CCmdInfo::GetValue int   RelativePos const [virtual]
 

Gets the enumeration of a specified label.

Parameters:
RelativePos   The position of the specified label in the command line.

Reimplemented from CCmdInfoData.


Friends And Related Function Documentation

std::ostream& operator<< std::ostream &   Stream,
const CCmdInfo &   CmdInfo
[friend]
 

Inserts in the specified stream the formatted command line info.


The documentation for this class was generated from the following files:
Top of Page
written by Pierre Rebours © 2000-2001. Terms of Use.