Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

vul_arg_base Class Reference

#include <vul_arg.h>

Inheritance diagram for vul_arg_base:

Inheritance graph
[legend]
List of all members.

Detailed Description

This is the base class for the templated vul_arg<T>s.

Definition at line 32 of file vul_arg.h.

Public Member Functions

char const * option ()
char const * help ()
bool set () const
 Returns true if arg was set on the command line.
virtual vcl_ostream & print_value (vcl_ostream &)=0

Static Public Member Functions

static void parse_deprecated (int &argc, char **&argv, bool warn_about_unrecognized_arguments=true)
 The main static method.
static void include_deprecated (vul_arg_info_list &l)
 Add another vul_arg_info_list to the current one.
static void add_to_current (vul_arg_base *a)
static void set_help_option (char const *str)
static void set_help_description (char const *str)
static void set_help_precis (char const *str)
static void display_usage (char const *msg=0)
static void display_usage_and_exit (char const *msg=0)

Public Attributes

char const * type_
 Static text describing type of option (e.g. bool or double).

Protected Member Functions

 vul_arg_base (vul_arg_info_list &l, char const *option_string, char const *helpstring)
 vul_arg_base (char const *option_string, char const *helpstring)
virtual ~vul_arg_base ()
virtual int parse (char **argv)=0

Protected Attributes

bool set_
 After parsing, true iff value was set on command line.
vcl_string option_
 Option flag including "-" or "--".
vcl_string help_
 Description of argument.

Friends

class vul_arg_info_list


Constructor & Destructor Documentation

vul_arg_base::vul_arg_base vul_arg_info_list l,
char const *  option_string,
char const *  helpstring
[protected]
 

Definition at line 125 of file vul_arg.cxx.

vul_arg_base::vul_arg_base char const *  option_string,
char const *  helpstring
[protected]
 

Definition at line 132 of file vul_arg.cxx.

virtual vul_arg_base::~vul_arg_base  )  [inline, protected, virtual]
 

Definition at line 72 of file vul_arg.h.


Member Function Documentation

void vul_arg_base::add_to_current vul_arg_base a  )  [static]
 

Definition at line 84 of file vul_arg.cxx.

void vul_arg_base::display_usage char const *  msg = 0  )  [static]
 

Definition at line 110 of file vul_arg.cxx.

void vul_arg_base::display_usage_and_exit char const *  msg = 0  )  [static]
 

Definition at line 116 of file vul_arg.cxx.

char const * vul_arg_base::help  ) 
 

Definition at line 41 of file vul_arg.cxx.

void vul_arg_base::include_deprecated vul_arg_info_list l  )  [static]
 

Add another vul_arg_info_list to the current one.

This allows for the inclusion of different sets of arguments into the main program, from different libraries.

Definition at line 78 of file vul_arg.cxx.

char const * vul_arg_base::option  ) 
 

Definition at line 38 of file vul_arg.cxx.

virtual int vul_arg_base::parse char **  argv  )  [protected, pure virtual]
 

Implemented in vul_arg< T >.

void vul_arg_base::parse_deprecated int &  argc,
char **&  argv,
bool  warn_about_unrecognized_arguments = true
[static]
 

The main static method.

Definition at line 90 of file vul_arg.cxx.

virtual vcl_ostream& vul_arg_base::print_value vcl_ostream &   )  [pure virtual]
 

Implemented in vul_arg< T >.

bool vul_arg_base::set  )  const
 

Returns true if arg was set on the command line.

Definition at line 66 of file vul_arg.cxx.

void vul_arg_base::set_help_description char const *  str  )  [static]
 

Definition at line 105 of file vul_arg.cxx.

void vul_arg_base::set_help_option char const *  str  )  [static]
 

Definition at line 95 of file vul_arg.cxx.

void vul_arg_base::set_help_precis char const *  str  )  [static]
 

Definition at line 100 of file vul_arg.cxx.


Friends And Related Function Documentation

friend class vul_arg_info_list [friend]
 

Definition at line 46 of file vul_arg.h.


Member Data Documentation

vcl_string vul_arg_base::help_ [protected]
 

Description of argument.

Definition at line 67 of file vul_arg.h.

vcl_string vul_arg_base::option_ [protected]
 

Option flag including "-" or "--".

Definition at line 65 of file vul_arg.h.

bool vul_arg_base::set_ [protected]
 

After parsing, true iff value was set on command line.

Definition at line 63 of file vul_arg.h.

char const* vul_arg_base::type_
 

Static text describing type of option (e.g. bool or double).

Definition at line 60 of file vul_arg.h.


The documentation for this class was generated from the following files:
Generated on Thu Jan 10 14:41:00 2008 for core/vul by  doxygen 1.4.4