a named constant corresponding to the DDL-XML tag <Constant> and <ConstantsStrVector> More...
#include <DDStrVector.h>
Public Types | |
typedef std::vector < std::string >::size_type | size_t |
size type for the size of the stored values | |
typedef std::vector< std::string > | value_type |
iterator for read-only acces to stored values | |
Public Member Functions | |
DDStrVector () | |
an uninitialized constant; one can assign an initialized constant to make it valid | |
DDStrVector (const DDName &name) | |
a refenrence to a constant | |
DDStrVector (const DDName &name, std::vector< std::string > *value) | |
creation of a new named constant; if it already existed with the given name, it's overwritten with new values | |
operator std::string () const | |
convert to a double | |
operator std::vector< std::string > () const | |
convert to a std::vector<double> | |
std::string | operator[] (size_t pos) const |
returns the value on position pos; does not check boundaries! | |
size_t | size () const |
the size of the array of values | |
std::string | value () const |
return the first stored value; does not check boundaries! | |
const value_type & | values () const |
the stored values | |
value_type::const_iterator | vectorBegin () const |
read-only iterator pointing to the begin of the stored values | |
value_type::const_iterator | vectorEnd () const |
read-only iterator poining one place after the stored values |
a named constant corresponding to the DDL-XML tag <Constant> and <ConstantsStrVector>
Definition at line 17 of file DDStrVector.h.
typedef std::vector<std::string>::size_type DDStrVector::size_t |
size type for the size of the stored values
Definition at line 22 of file DDStrVector.h.
typedef std::vector<std::string> DDStrVector::value_type |
iterator for read-only acces to stored values
value type of the managed object
Definition at line 28 of file DDStrVector.h.
DDStrVector::DDStrVector | ( | ) |
an uninitialized constant; one can assign an initialized constant to make it valid
Definition at line 6 of file DDStrVector.cc.
: DDBase<DDName,std::vector<std::string>*>() { }
DDStrVector::DDStrVector | ( | const DDName & | name | ) |
a refenrence to a constant
Definition at line 9 of file DDStrVector.cc.
References DDI::Singleton< I >::instance(), and DDBase< DDName, std::vector< std::string > * >::prep_.
: DDBase<DDName,std::vector<std::string>*>() { prep_ = StoreT::instance().create(name); }
DDStrVector::DDStrVector | ( | const DDName & | name, |
std::vector< std::string > * | value | ||
) |
creation of a new named constant; if it already existed with the given name, it's overwritten with new values
Definition at line 14 of file DDStrVector.cc.
References DDI::Singleton< I >::instance(), and DDBase< DDName, std::vector< std::string > * >::prep_.
{ prep_ = StoreT::instance().create(name,vals); }
DDStrVector::operator std::string | ( | ) | const [inline] |
convert to a double
Definition at line 58 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
{ return rep()[0]; }
DDStrVector::operator std::vector< std::string > | ( | ) | const [inline] |
convert to a std::vector<double>
Definition at line 61 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
{ return rep(); }
std::string DDStrVector::operator[] | ( | size_t | pos | ) | const [inline] |
returns the value on position pos; does not check boundaries!
Definition at line 46 of file DDStrVector.h.
References pos, and DDBase< DDName, std::vector< std::string > * >::rep().
size_t DDStrVector::size | ( | void | ) | const [inline] |
the size of the array of values
Definition at line 40 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
Referenced by operator<<().
{ return rep().size(); }
std::string DDStrVector::value | ( | ) | const [inline] |
return the first stored value; does not check boundaries!
Definition at line 49 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
{ return rep()[0]; }
const value_type& DDStrVector::values | ( | ) | const [inline] |
the stored values
Definition at line 43 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
Referenced by operator<<().
{ return rep(); }
value_type::const_iterator DDStrVector::vectorBegin | ( | ) | const [inline] |
read-only iterator pointing to the begin of the stored values
Definition at line 52 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
{ return rep().begin(); }
value_type::const_iterator DDStrVector::vectorEnd | ( | ) | const [inline] |
read-only iterator poining one place after the stored values
Definition at line 55 of file DDStrVector.h.
References DDBase< DDName, std::vector< std::string > * >::rep().
{ return rep().end(); }