vSMC  v3.0.0
Scalable Monte Carlo
Public Member Functions | List of all members
vsmc::ProgramOptionScalar< T > Class Template Reference

Option with a single value. More...

#include <vsmc/utility/program_option.hpp>

Public Member Functions

 ProgramOptionScalar (const std::string &desc, T *ptr)
 
template<typename V >
 ProgramOptionScalar (const std::string &desc, T *ptr, V val)
 
bool is_vector () const
 
bool set (const std::string &name, const std::string &sval, bool silent, std::ostream &os)
 
bool set_default ()
 
- Public Member Functions inherited from vsmc::ProgramOptionDefault< T >
 ProgramOptionDefault (const std::string &desc)
 
template<typename V >
 ProgramOptionDefault (const std::string &desc, V val)
 
std::string default_str () const
 
std::string description () const
 
bool is_bool () const
 
- Public Member Functions inherited from vsmc::ProgramOption
 ProgramOption ()=default
 
 ProgramOption (const ProgramOption &)=default
 
virtual ~ProgramOption ()
 
ProgramOptionoperator= (const ProgramOption &)=default
 

Additional Inherited Members

- Protected Member Functions inherited from vsmc::ProgramOptionDefault< T >
bool set_value_default (T *dest)
 
- Protected Member Functions inherited from vsmc::ProgramOption
bool set_value (const std::string &name, const std::string &sval, bool *dest, bool silent, std::ostream &os)
 
bool set_value (const std::string &, const std::string &sval, std::string *dest, bool, std::ostream &)
 
template<typename T >
bool set_value (const std::string &name, const std::string &sval, T *dest, bool silent, std::ostream &os)
 

Detailed Description

template<typename T>
class vsmc::ProgramOptionScalar< T >

Option with a single value.

Definition at line 261 of file program_option.hpp.

Constructor & Destructor Documentation

template<typename T >
vsmc::ProgramOptionScalar< T >::ProgramOptionScalar ( const std::string &  desc,
T *  ptr 
)
inline

Definition at line 264 of file program_option.hpp.

template<typename T >
template<typename V >
vsmc::ProgramOptionScalar< T >::ProgramOptionScalar ( const std::string &  desc,
T *  ptr,
val 
)
inline

Definition at line 270 of file program_option.hpp.

Member Function Documentation

template<typename T >
bool vsmc::ProgramOptionScalar< T >::is_vector ( ) const
inlinevirtual

Implements vsmc::ProgramOption.

Definition at line 275 of file program_option.hpp.

template<typename T >
bool vsmc::ProgramOptionScalar< T >::set ( const std::string &  name,
const std::string &  sval,
bool  silent,
std::ostream &  os 
)
inlinevirtual

Implements vsmc::ProgramOption.

Definition at line 277 of file program_option.hpp.

template<typename T >
bool vsmc::ProgramOptionScalar< T >::set_default ( )
inlinevirtual

Implements vsmc::ProgramOption.

Definition at line 283 of file program_option.hpp.