blitzdg
an open-source project aiming to implement parallel discontinuous Galerkin (dg) solvers for common partial differential equations systems using blitz++ for array and tensor manipulations and MPI for distributed parallelism.
stringizers.h
1 
2 // Copyright Joakim Karlsson & Kim Gräsman 2010-2013.
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt or copy at
5 // http://www.boost.org/LICENSE_1_0.txt)
6 
7 #ifndef IGLOO_STRINGIZERS_H
8 #define IGLOO_STRINGIZERS_H
9 
10 namespace snowhouse
11 {
12 
13  namespace detail
14  {
15 
16  template<typename Container>
18  {
19  static std::string
20  ToString(const Container& cont)
21  {
22  std::ostringstream stm;
23  typedef typename Container::const_iterator Iterator;
24 
25  stm << "[ ";
26  for (Iterator it = cont.begin(); it != cont.end();)
27  {
28  stm << snowhouse::Stringize(*it);
29 
30  if (++it != cont.end())
31  {
32  stm << ", ";
33  }
34  }
35  stm << " ]";
36  return stm.str();
37  }
38  };
39  }
40 
41  template<typename T>
43  std::vector<T> >
44  {
45  };
46 
47  template<typename T>
49  std::deque<T> >
50  {
51  };
52 
53  template<typename T>
55  std::list<T> >
56  {
57  };
58 }
59 
60 #endif
Definition: assert.h:13
Definition: stringize.h:71