Flow123d  jenkins-Flow123d-windows32-release-multijob-163
Public Member Functions | Private Attributes | Friends | List of all members
Input::Type::Double Class Reference

Class for declaration of the input data that are floating point numbers. More...

#include <type_base.hh>

Inheritance diagram for Input::Type::Double:
Inheritance graph
[legend]
Collaboration diagram for Input::Type::Double:
Collaboration graph
[legend]

Public Member Functions

 Double (double lower_bound=-std::numeric_limits< double >::max(), double upper_bound=std::numeric_limits< double >::max())
 
std::size_t content_hash () const override
 
bool match (double value) const
 
virtual bool valid_default (const string &str) const
 Implements Type::TypeBase::valid_defaults. More...
 
double from_default (const string &str) const
 
virtual string type_name () const
 Returns an identification of the type. Useful for error messages. More...
 
- Public Member Functions inherited from Input::Type::Scalar
virtual string full_type_name () const
 Returns an identification of the type in format "type_name():parent->type_name()". More...
 
- Public Member Functions inherited from Input::Type::TypeBase
virtual bool is_finished () const
 
string desc () const
 
virtual bool operator== (const TypeBase &other) const
 
bool operator!= (const TypeBase &other) const
 Comparison of types. More...
 
virtual ~TypeBase ()
 
virtual bool finish ()
 

Private Attributes

double lower_bound_
 
double upper_bound_
 

Friends

class OutputBase
 

Additional Inherited Members

- Static Public Member Functions inherited from Input::Type::TypeBase
static void lazy_finish ()
 Finishes all registered lazy types. More...
 
- Protected Types inherited from Input::Type::TypeBase
typedef string KeyHash
 
typedef std::vector
< boost::shared_ptr< TypeBase > > 
LazyTypeVector
 
typedef std::set< const
TypeBase * > 
LazyObjectsSet
 
- Protected Member Functions inherited from Input::Type::TypeBase
 TypeBase ()
 
 TypeBase (const TypeBase &other)
 
- Static Protected Member Functions inherited from Input::Type::TypeBase
static KeyHash key_hash (const string &str)
 Hash function. More...
 
static bool is_valid_identifier (const string &key)
 
static LazyTypeVectorlazy_type_list ()
 
static LazyObjectsSetlazy_object_set ()
 
static bool was_constructed (const TypeBase *ptr)
 

Detailed Description

Class for declaration of the input data that are floating point numbers.

The data are stored in an double variable. You can specify bounds for the valid input data.

Definition at line 392 of file type_base.hh.

Constructor & Destructor Documentation

Input::Type::Double::Double ( double  lower_bound = -std::numeric_limits<double>::max(),
double  upper_bound = std::numeric_limits<double>::max() 
)
inline

Definition at line 396 of file type_base.hh.

Member Function Documentation

std::size_t Input::Type::Double::content_hash ( ) const
overridevirtual

Hash of the type specification. Provides unique id computed from its content (definition) so that same types have same hash.

Implements Input::Type::TypeBase.

Definition at line 363 of file type_base.cc.

Here is the caller graph for this function:

double Input::Type::Double::from_default ( const string &  str) const

As before but also returns converted integer in value.

Definition at line 380 of file type_base.cc.

Here is the caller graph for this function:

bool Input::Type::Double::match ( double  value) const

Returns true if the given integer value conforms to the Type::Double bounds.

Definition at line 374 of file type_base.cc.

Here is the caller graph for this function:

string Input::Type::Double::type_name ( ) const
virtual

Returns an identification of the type. Useful for error messages.

Reimplemented from Input::Type::TypeBase.

Definition at line 403 of file type_base.cc.

Here is the caller graph for this function:

bool Input::Type::Double::valid_default ( const string &  str) const
virtual

Implements Type::TypeBase::valid_defaults.

Implements Input::Type::TypeBase.

Definition at line 394 of file type_base.cc.

Friends And Related Function Documentation

friend class OutputBase
friend

Definition at line 393 of file type_base.hh.

Member Data Documentation

double Input::Type::Double::lower_bound_
private

Definition at line 419 of file type_base.hh.

double Input::Type::Double::upper_bound_
private

Definition at line 419 of file type_base.hh.


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