GetOpt Class Reference

#include <qgetopt.h>

List of all members.

Classes

struct  Option

Public Member Functions

void addArgument (const QString &name, const QString &description, QVariant *v)
void addOption (char s, const QString &longname, const QString &description, QVariant *v)
void addOptionalArgument (const QString &name, const QString &description, QVariant *v)
void addSwitch (char s, const QString &longname, const QString &description, bool *b)
void allowUnlimitedArguments (bool allow)
QString & applicationName ()
 GetOpt (const QStringList &a)
 GetOpt (int argc, char *argv[])
 GetOpt ()
void parse ()
void setHelp (QString &_help)
QString usage ()

Public Attributes

QString appname
QStringList args
QStringList arguments
QString help

Protected Member Functions

bool findArg (const QString &name, Option &option)
bool findOption (char c, Option &option)
QString formatDesc (QString desc, int len)
bool parse (QString &error)

Protected Attributes

QList< Optionoptions
bool unlimitedArgs

Detailed Description

Definition at line 46 of file qgetopt.h.


Constructor & Destructor Documentation

GetOpt::GetOpt (  )  [inline]

Definition at line 66 of file qgetopt.h.

GetOpt::GetOpt ( int  argc,
char *  argv[] 
)

Definition at line 32 of file qgetopt.cpp.

GetOpt::GetOpt ( const QStringList &  a  ) 

Definition at line 38 of file qgetopt.cpp.


Member Function Documentation

void GetOpt::addArgument ( const QString &  name,
const QString &  description,
QVariant *  v 
)

Definition at line 70 of file qgetopt.cpp.

void GetOpt::addOption ( char  s,
const QString &  longname,
const QString &  description,
QVariant *  v 
)

Definition at line 58 of file qgetopt.cpp.

void GetOpt::addOptionalArgument ( const QString &  name,
const QString &  description,
QVariant *  v 
)

Definition at line 80 of file qgetopt.cpp.

void GetOpt::addSwitch ( char  s,
const QString &  longname,
const QString &  description,
bool *  b 
)

Definition at line 45 of file qgetopt.cpp.

void GetOpt::allowUnlimitedArguments ( bool  allow  )  [inline]

Definition at line 83 of file qgetopt.h.

QString & GetOpt::applicationName (  ) 

Definition at line 90 of file qgetopt.cpp.

bool GetOpt::findArg ( const QString &  name,
Option option 
) [protected]

Definition at line 290 of file qgetopt.cpp.

bool GetOpt::findOption ( char  c,
Option option 
) [protected]

Definition at line 278 of file qgetopt.cpp.

QString GetOpt::formatDesc ( QString  desc,
int  len 
) [protected]

Definition at line 301 of file qgetopt.cpp.

bool GetOpt::parse ( QString &  error  )  [protected]

Definition at line 166 of file qgetopt.cpp.

void GetOpt::parse (  ) 

Definition at line 158 of file qgetopt.cpp.

void GetOpt::setHelp ( QString &  _help  )  [inline]

Definition at line 86 of file qgetopt.h.

QString GetOpt::usage (  ) 

Definition at line 95 of file qgetopt.cpp.


Member Data Documentation

QString GetOpt::appname

Definition at line 61 of file qgetopt.h.

QStringList GetOpt::args

Definition at line 63 of file qgetopt.h.

QStringList GetOpt::arguments

Definition at line 64 of file qgetopt.h.

QString GetOpt::help

Definition at line 62 of file qgetopt.h.

QList<Option> GetOpt::options [protected]

Definition at line 58 of file qgetopt.h.

bool GetOpt::unlimitedArgs [protected]

Definition at line 57 of file qgetopt.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


vcglib
Author(s): Christian Bersch
autogenerated on Fri Jan 11 09:22:04 2013