Class template to support defining containers using a comma separated list as in the following example. More...
#include <cslisttag.h>
Public Member Functions | |
CsListTag (const Fun &f=Fun()) | |
CsListTag & | operator= (const Elem &v) |
CsListTag & | operator, (const Elem &v) |
operator Container () | |
Public Attributes | |
Container | c |
Fun | fun |
Class template to support defining containers using a comma separated list as in the following example.
TODO: example and explanation of 3rd template arg
typedef CsListTag<const char*, std::vector<std::string> NamesTag; Namestag names; std::vector<std::string> list1((names = "abc", "def", "ghi")); std::vector<std::string> list2((names = "123", "xyz"));
Requirements on Container:
Container::Container()
Container::clear()
Container::push_back(const V&)
Requirements on Elem:
Elem::Elem(const Elem&)
Definition at line 45 of file cslisttag.h.
Dv::Util::CsListTag< Container, Elem, Fun >::CsListTag | ( | const Fun & | f = Fun() |
) | [inline] |
Definition at line 46 of file cslisttag.h.
CsListTag& Dv::Util::CsListTag< Container, Elem, Fun >::operator= | ( | const Elem & | v | ) | [inline] |
Definition at line 48 of file cslisttag.h.
References Dv::Util::CsListTag< Container, Elem, Fun >::c, and Dv::Util::CsListTag< Container, Elem, Fun >::fun.
CsListTag& Dv::Util::CsListTag< Container, Elem, Fun >::operator, | ( | const Elem & | v | ) | [inline] |
Definition at line 53 of file cslisttag.h.
References Dv::Util::CsListTag< Container, Elem, Fun >::c, and Dv::Util::CsListTag< Container, Elem, Fun >::fun.
Dv::Util::CsListTag< Container, Elem, Fun >::operator Container | ( | ) | [inline] |
Definition at line 57 of file cslisttag.h.
References Dv::Util::CsListTag< Container, Elem, Fun >::c.
Container Dv::Util::CsListTag< Container, Elem, Fun >::c |
Definition at line 47 of file cslisttag.h.
Referenced by Dv::Util::CsListTag< Container, Elem, Fun >::operator Container(), Dv::Util::CsListTag< Container, Elem, Fun >::operator,(), and Dv::Util::CsListTag< Container, Elem, Fun >::operator=().
Fun Dv::Util::CsListTag< Container, Elem, Fun >::fun |
Definition at line 58 of file cslisttag.h.
Referenced by Dv::Util::CsListTag< Container, Elem, Fun >::operator,(), and Dv::Util::CsListTag< Container, Elem, Fun >::operator=().
dvutil-1.0.10 | [ 5 December, 2009] |