]> Dogcows Code - chaz/yoink/blob - src/stlplus/strings/string_map.hpp
build system enhancements
[chaz/yoink] / src / stlplus / strings / string_map.hpp
1 #ifndef STLPLUS_STRING_MAP
2 #define STLPLUS_STRING_MAP
3 ////////////////////////////////////////////////////////////////////////////////
4
5 // Author: Andy Rushton
6 // Copyright: (c) Southampton University 1999-2004
7 // (c) Andy Rushton 2004-2009
8 // License: BSD License, see ../docs/license.html
9
10 // Generate a string representation of a map/multimap
11
12 ////////////////////////////////////////////////////////////////////////////////
13 #include "strings_fixes.hpp"
14 #include <string>
15 #include <map>
16
17 namespace stlplus
18 {
19
20 template<typename K, typename T, typename C, typename SK, typename ST>
21 std::string map_to_string(const std::map<K,T,C>& values,
22 SK key_to_string_fn,
23 ST value_to_string_fn,
24 const std::string& pair_separator = ":",
25 const std::string& separator = ",");
26
27 template<typename K, typename T, typename C, typename SK, typename ST>
28 std::string multimap_to_string(const std::multimap<K,T,C>& values,
29 SK key_to_string_fn,
30 ST value_to_string_fn,
31 const std::string& pair_separator = ":",
32 const std::string& separator = ",");
33
34 } // end namespace stlplus
35
36 #include "string_map.tpp"
37 #endif
This page took 0.029452 seconds and 4 git commands to generate.