yosys-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Minisat::StringOption Class Reference

#include <Options.h>

+ Inheritance diagram for Minisat::StringOption:
+ Collaboration diagram for Minisat::StringOption:

Public Member Functions

 StringOption (const char *c, const char *n, const char *d, const char *def=NULL)
 
 operator const char * (void) const
 
 operator const char *& (void)
 
StringOptionoperator= (const char *x)
 
virtual bool parse (const char *str)
 
virtual void help (bool verbose=false)
 

Static Protected Member Functions

static vec< Option * > & getOptionList ()
 
static const char *& getUsageString ()
 
static const char *& getHelpPrefixString ()
 

Protected Attributes

const char * name
 
const char * description
 
const char * category
 
const char * type_name
 

Private Attributes

const char * value
 

Detailed Description

Definition at line 306 of file Options.h.

Constructor & Destructor Documentation

Minisat::StringOption::StringOption ( const char *  c,
const char *  n,
const char *  d,
const char *  def = NULL 
)
inline

Definition at line 310 of file Options.h.

311  : Option(n, d, c, "<string>"), value(def) {}
tuple n
Definition: fsm/generate.py:59
const char * value
Definition: Options.h:308
Option(const char *name_, const char *desc_, const char *cate_, const char *type_)
Definition: Options.h:67

Member Function Documentation

static const char*& Minisat::Option::getHelpPrefixString ( )
inlinestaticprotectedinherited

Definition at line 58 of file Options.h.

58 { static const char* help_prefix_str = ""; return help_prefix_str; }

+ Here is the caller graph for this function:

static vec<Option*>& Minisat::Option::getOptionList ( )
inlinestaticprotectedinherited

Definition at line 56 of file Options.h.

56 { static vec<Option*> options; return options; }

+ Here is the caller graph for this function:

static const char*& Minisat::Option::getUsageString ( )
inlinestaticprotectedinherited

Definition at line 57 of file Options.h.

57 { static const char* usage_str; return usage_str; }

+ Here is the caller graph for this function:

virtual void Minisat::StringOption::help ( bool  verbose = false)
inlinevirtual

Implements Minisat::Option.

Definition at line 327 of file Options.h.

327  {
328  fprintf(stderr, " -%-10s = %8s\n", name, type_name);
329  if (verbose){
330  fprintf(stderr, "\n %s\n", description);
331  fprintf(stderr, "\n");
332  }
333  }
const char * name
Definition: Options.h:51
const char * type_name
Definition: Options.h:54
const char * description
Definition: Options.h:52
Minisat::StringOption::operator const char * ( void  ) const
inline

Definition at line 313 of file Options.h.

313 { return value; }
const char * value
Definition: Options.h:308
Minisat::StringOption::operator const char *& ( void  )
inline

Definition at line 314 of file Options.h.

314 { return value; }
const char * value
Definition: Options.h:308
StringOption& Minisat::StringOption::operator= ( const char *  x)
inline

Definition at line 315 of file Options.h.

315 { value = x; return *this; }
const char * value
Definition: Options.h:308
virtual bool Minisat::StringOption::parse ( const char *  str)
inlinevirtual

Implements Minisat::Option.

Definition at line 317 of file Options.h.

317  {
318  const char* span = str;
319 
320  if (!match(span, "-") || !match(span, name) || !match(span, "="))
321  return false;
322 
323  value = span;
324  return true;
325  }
const char * name
Definition: Options.h:51
const char * value
Definition: Options.h:308
static bool match(B &in, const char *str)
Definition: ParseUtils.h:96

+ Here is the call graph for this function:

Field Documentation

const char* Minisat::Option::category
protectedinherited

Definition at line 53 of file Options.h.

const char* Minisat::Option::description
protectedinherited

Definition at line 52 of file Options.h.

const char* Minisat::Option::name
protectedinherited

Definition at line 51 of file Options.h.

const char* Minisat::Option::type_name
protectedinherited

Definition at line 54 of file Options.h.

const char* Minisat::StringOption::value
private

Definition at line 308 of file Options.h.


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