vg
tools for working with variation graphs
Loading...
Searching...
No Matches
vg::OptionValueParser< vector< Item > > Class Template Reference

#include <option.hpp>

Public Member Functions

bool has_argument ()
void parse_default (const bool &default_value, bool &value)
void parse (const string &arg, bool &value)
string unparse (const bool &value)

Static Public Member Functions

static bool has_argument ()
static void parse_default (const vector< Item > &default_value, vector< Item > &value)
static void parse (const string &arg, vector< Item > &value)
static string unparse (const vector< Item > &value)

Detailed Description

template<typename Item>
class vg::OptionValueParser< vector< Item > >

For vector options, we recurse.

Member Function Documentation

◆ has_argument() [1/2]

template<typename Item>
bool vg::OptionValueParser< vector< Item > >::has_argument ( )
inlinestatic

Return true if we need an argument and false otherwise.

◆ has_argument() [2/2]

bool vg::OptionValueParser< bool >::has_argument ( )
inline

Bool options don't need arguments.

◆ parse() [1/2]

void vg::OptionValueParser< bool >::parse ( const string & arg,
bool & value )
inline

If someone gives a value to a bool, explode.

◆ parse() [2/2]

template<typename Item>
void vg::OptionValueParser< vector< Item > >::parse ( const string & arg,
vector< Item > & value )
inlinestatic

Parse from an argument.

◆ parse_default() [1/2]

void vg::OptionValueParser< bool >::parse_default ( const bool & default_value,
bool & value )
inline

When someone gives a bool option they mean to invert its default value.

◆ parse_default() [2/2]

template<typename Item>
void vg::OptionValueParser< vector< Item > >::parse_default ( const vector< Item > & default_value,
vector< Item > & value )
inlinestatic

Parse from no argument, but a default value.

◆ unparse() [1/2]

string vg::OptionValueParser< bool >::unparse ( const bool & value)
inline

Represent default values for bools as true and false.

◆ unparse() [2/2]

template<typename Item>
string vg::OptionValueParser< vector< Item > >::unparse ( const vector< Item > & value)
inlinestatic

Stringify a default value.


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