Lumiera  0.pre.03
»edit your freedom«
Cmdline Class Reference

#include "lib/cmdline.hpp"

Description

Abstraction of the usual int argc, int** argv-Commandline, to be able to treat it as a vector of strings.

Inherits from vector<std::string>, but provides convenient conversions to string (joining delimited by space)...

Definition at line 57 of file cmdline.hpp.

Public Member Functions

 Cmdline (int argc, const char **argv)
 create as a tokenised copy of the current commandline. More...
 
 Cmdline (const string cmdline)
 create by tokenising a string (e.g. More...
 
template<class In >
 Cmdline (In first, In last)
 
 operator string () const
 conversion to string by joining the tokens
 
VectS & operator= (const VectS &source)
 

Constructor & Destructor Documentation

◆ Cmdline() [1/2]

Cmdline ( int  argc,
const char **  argv 
)

create as a tokenised copy of the current commandline.

Note that argv[0] is always ignored.

Definition at line 50 of file cmdline.cpp.

◆ Cmdline() [2/2]

Cmdline ( const string  cmdline)
explicit

create by tokenising a string (e.g.

"fake" cmdline, separated by whitespace)

Definition at line 64 of file cmdline.cpp.

+ Inheritance diagram for Cmdline:
+ Collaboration diagram for Cmdline:

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