#include <val.h>


Some typedefs are already defined for some more common conversions.
Please note that all combinations are not possible. You can get compilation error or an exception at run-time. Make sure that you try to bind converter and target value that fit.
typedef val_List<val_String, string> val_StringList;
| CNV | Conversion class type | |
| DT | Destination type |
Definition at line 955 of file val.h.
Public Types | |
| typedef vector< val_Element< DT > > | listVecType |
Public Member Functions | |
| val_List (const string &a_name, const val_Limit a_limits, const UInt32_t a_minNumOfVal=1, const UInt64_t a_maxNumOfVal=cfg_INFINITE) | |
| virtual | ~val_List () |
| virtual void | Bind (listVecType &a_dest) |
| virtual void | Add (const string &a_strVal) |
| virtual void | AddRange (const string &a_strLow, const string &a_strHigh) |
| virtual void | Assign (const string &a_strVal) |
Protected Attributes | |
| listVecType * | m_vec_p |
| log_CLASSID_m | |
| typedef vector< val_Element<DT> > val_List< CNV, DT >::listVecType |
| virtual void val_List< CNV, DT >::Bind | ( | listVecType & | a_dest | ) | [inline, virtual] |
| virtual void val_List< CNV, DT >::Add | ( | const string & | a_strVal | ) | [inline, virtual] |
Reimplemented from val_Value.
Reimplemented in val_SlotList.
Definition at line 980 of file val.h.
00980 { 00981 if (m_vec_p == NULL) { 00982 throw ivd_Error(ie_INVALID_ARG, 00983 "Target vector not specified."); 00984 } 00985 00986 DT basicTmp; 00987 CNV converter("", m_limits); 00988 00989 converter.Bind(basicTmp); 00990 00991 try { 00992 converter.Conv(a_strVal); 00993 } 00994 catch (ivd_Error& e){ 00995 ostringstream eNew; 00996 eNew << "Error occured in list:" << m_name << 00997 " at index:" << static_cast<unsigned int>(m_vec_p->size()) << 00998 " " << e.GetContext(); 00999 throw ivd_Error(e.GetError(), eNew.str() ); 01000 } 01001 01002 val_Element<DT> valElem(basicTmp); 01003 m_vec_p->push_back(valElem); 01004 }
| virtual void val_List< CNV, DT >::AddRange | ( | const string & | a_strLow, | |
| const string & | a_strHigh | |||
| ) | [inline, virtual] |
Reimplemented from val_Value.
Reimplemented in val_SlotList, and val_FileNamePatternList.
Definition at line 1006 of file val.h.
01007 { 01008 01009 if (m_vec_p == NULL) { 01010 throw ivd_Error(ie_INVALID_ARG, 01011 "Target vector not specified."); 01012 }; 01013 01014 val_Element<DT> rangeElem; 01015 val_Range<CNV, DT> converter("", m_limits); 01016 01017 converter.Bind(rangeElem); 01018 try { 01019 converter.Conv(a_strLow, a_strHigh); 01020 } 01021 catch (ivd_Error& e){ 01022 ostringstream eNew; 01023 eNew << "Error occured in list:" << m_name << 01024 " at index:" << static_cast<unsigned int>(m_vec_p->size()) << 01025 " " << e.GetContext(); 01026 throw ivd_Error(e.GetError(), eNew.str() ); 01027 } 01028 01029 m_vec_p->push_back(rangeElem); 01030 }
| virtual void val_List< CNV, DT >::Assign | ( | const string & | a_strVal | ) | [inline, virtual] |
Implements val_BasicValue.
Definition at line 1032 of file val.h.
01032 { 01033 throw ivd_Error(ie_PARSER_ERROR, 01034 "Lists don't have Assign() function."); 01035 }
listVecType* val_List< CNV, DT >::m_vec_p [protected] |
val_List< CNV, DT >::log_CLASSID_m [protected] |
1.5.6