dbp::cmdline_parameters Class Reference

Command line parser. More...

#include <cmdline_parameters.h>

List of all members.

Public Types

typedef std::vector
< cmdline_parameter
params
 Command line parameters.

Public Member Functions

 cmdline_parameters ()
 Constructor.
void add (const cmdline_parameter &param)
 Register known command line parameter.
bool parse (int argc, char *argv[], cmdline_parameter &param)
 Parse command line.
params::const_iterator begin () const
 Registered command line parameters iterator.
params::const_iterator end () const
 Registered command line parameters iterator.

Detailed Description

Command line parser.

This class represents application command line parameter list and parser.


Member Function Documentation

params::const_iterator dbp::cmdline_parameters::begin (  )  const

Registered command line parameters iterator.

Returns the iterator for the beginning of registered command line parameters collection.

params::const_iterator dbp::cmdline_parameters::end (  )  const

Registered command line parameters iterator.

Returns the iterator for the ending of registered command line parameters collection.

bool dbp::cmdline_parameters::parse ( int  argc,
char *  argv[],
cmdline_parameter param 
)

Parse command line.

Parses given command line. After sequential calls iterates throw all command line parameters found.

Parameters:
argc the command line parameters count.
argv[] pointer to the command line.
param (out) the next command line parameter found.
Returns:
true if one more command line parameter exist and false otherwise.

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

 
Support This Project
SourceForge.net Logo