1#ifndef __cxxtest_StdValueTraits_h__
2#define __cxxtest_StdValueTraits_h__
13#ifdef _CXXTEST_OLD_STD
14# define CXXTEST_STD(x) x
16# define CXXTEST_STD(x) std::x
19#ifndef CXXTEST_USER_VALUE_TRAITS
37 const char *
asString()
const {
return _s.c_str(); }
53 for (
unsigned i = 0;
i <
s.length(); ++
i ) {
54 char c[
sizeof(
"\\xXX")];
64#ifndef _CXXTEST_OLD_STD
75 for (
unsigned i = 0;
i <
s.length(); ++
i ) {
76 char c[
sizeof(
"\\x12345678")];
91 template<
class Stream,
class Iterator>
95 while ( first !=
last ) {
98 s << ((first ==
last) ?
" }" :
", ");
102#ifdef _CXXTEST_PARTIAL_TEMPLATE_SPECIALIZATION
106 template<
class First,
class Second>
107 class ValueTraits<
CXXTEST_STD(pair)<First, Second> > :
public StdTraitsBase
110 ValueTraits(
const CXXTEST_STD(pair)<First, Second> &
p )
119 template<
class Element>
120 class ValueTraits<
CXXTEST_STD(vector)<Element> > :
public StdTraitsBase
132 template<
class Element>
133 class ValueTraits<
CXXTEST_STD(list)<Element> > :
public StdTraitsBase
145 template<
class Element>
146 class ValueTraits<
CXXTEST_STD(set)<Element> > :
public StdTraitsBase
158 template<
class Key,
class Value>
159 class ValueTraits<
CXXTEST_STD(
map)<Key, Value> > :
public StdTraitsBase
171 template<
class Element>
172 class ValueTraits<
CXXTEST_STD(deque)<Element> > :
public StdTraitsBase
184 template<
class Element>
185 class ValueTraits<
CXXTEST_STD(multiset)<Element> > :
public StdTraitsBase
190 dumpRange( *
this, ms.begin(), ms.end() );
197 template<
class Key,
class Value>
198 class ValueTraits<
CXXTEST_STD(multimap)<Key, Value> > :
public StdTraitsBase
203 dumpRange( *
this, mm.begin(), mm.end() );
210 template<
class Number>
218 else if ( !c.real() )
#define CXXTEST_TEMPLATE_INSTANTIATION
#define CXXTEST_COPY_CONST_TRAITS(CXXTEST_CLASS)
CanonicalForm map(const CanonicalForm &primElem, const Variable &alpha, const CanonicalForm &F, const Variable &beta)
map from to such that is mapped onto
const char * asString() const
StdTraitsBase & operator<<(const CXXTEST_STD(string) &s)
ValueTraits(const CXXTEST_STD(basic_string< wchar_t >) &s)
ValueTraits(const CXXTEST_STD(string) &s)
const Variable & v
< [in] a sqrfree bivariate poly
void dumpRange(Stream &s, Iterator first, Iterator last)
char * charToString(unsigned long c, char *s)