Xfce Foundation Classes
Main Page | Index | Namespace List | Alphabetical List | Class List | File List

# option.hh File Reference

A C++ interface for the GLib commandline option parser. More...

`#include <xfc/object.hh>`
`#include <glib/goption.h>`
`#include <vector>`
`#include <xfc/glib/inline/option.inl>`

## Namespaces

- namespace Xfc
- namespace Xfc::G

## Classes

- class Xfc::G::OptionContext
    A C++ wrapper interface for GOptionContext. More...
- class Xfc::G::OptionGroup
    A C++ wrapper interface for the GOptionGroup. More...

## Typedefs

- typedef unsigned int OptionFlagsField
    G::OptionFlagsField holds one or more bit values from the G::OptionFlags enumeration.

## Enumerations

- enum OptionError {
  OPTION_ERROR_UNKNOWN_OPTION = G_OPTION_ERROR_UNKNOWN_OPTION,
  OPTION_ERROR_BAD_VALUE = G_OPTION_ERROR_BAD_VALUE
  }
    Specifies the error codes returned by option parsing. More...
- enum OptionFlags {
  OPTION_FLAG_HIDDEN = G_OPTION_FLAG_HIDDEN,
  OPTION_FLAG_IN_MAIN = G_OPTION_FLAG_IN_MAIN,
  OPTION_FLAG_REVERSE = G_OPTION_FLAG_REVERSE
  }
    Specifies the flags which modify individual options. More...

## Detailed Description

A C++ interface for the GLib commandline option parser.

Provides G::OptionContext, an object that defines which options are accepted by the commandline option parser, and G::OptionGroup, an object that defines the options in a single group.

## Enumeration Type Documentation

enum OptionError

Specifies the error codes returned by option parsing.

Enumeration values:

  OPTION_ERROR_UNKNOWN_OPTION | An option was not known to the parser; this error will only be reported, if the parser hasn't been instructed to ignore unknown options (see set_ignore_unknown_options()).
  OPTION_ERROR_BAD_VALUE | A value couldn't be parsed.

enum OptionFlags

Specifies the flags which modify individual options.

Enumeration values:

  OPTION_FLAG_HIDDEN | The option doesn't appear in --help output.
  OPTION_FLAG_IN_MAIN | The option appears in the main section of the --help output, even if it is defined in a group.
  OPTION_FLAG_REVERSE | For options of the G_OPTION_ARG_NONE kind, this flag indicates that the sense of the option is reversed.

Xfce Foundation Classes

Copyright © 2004-2005 The XFC Development Team | XFC 4.3