25 mapi_t::const_iterator it =
map.begin();
26 mapi_t::const_iterator end =
map.end();
27 for (; it != end; ++it) {
28 std::cout << it->first <<
" " << it->second <<
"\n";
35 std::vector<std::string> out;
36 out.reserve (
map.size());
37 mapi_t::const_iterator it =
map.begin();
38 mapi_t::const_iterator end =
map.end();
39 for (; it != end; ++it) {
40 out.push_back (it->first);
49 out.reserve (
map.size());
50 mapi_t::const_iterator it =
map.begin();
51 mapi_t::const_iterator end =
map.end();
52 for (; it != end; ++it) {
53 out.push_back (it->second);
67 mapf_t::const_iterator it =
map.begin();
68 mapf_t::const_iterator end =
map.end();
69 for (; it != end; ++it) {
70 std::cout << it->first <<
" " << it->second <<
"\n";
77 std::vector<std::string> out;
78 out.reserve (
map.size());
79 mapf_t::const_iterator it =
map.begin();
80 mapf_t::const_iterator end =
map.end();
81 for (; it != end; ++it) {
82 out.push_back (it->first);
90 std::vector<float> out;
91 out.reserve (
map.size());
92 mapf_t::const_iterator it =
map.begin();
93 mapf_t::const_iterator end =
map.end();
94 for (; it != end; ++it) {
95 out.push_back (it->second);
109 maps_t::const_iterator it =
map.begin();
110 maps_t::const_iterator end =
map.end();
111 for (; it != end; ++it) {
112 std::cout << it->first <<
" " << it->second <<
"\n";
119 std::vector<std::string> out;
120 out.reserve (
map.size());
121 maps_t::const_iterator it =
map.begin();
122 maps_t::const_iterator end =
map.end();
123 for (; it != end; ++it) {
124 out.push_back (it->first);
132 std::vector<std::string> out;
133 out.reserve (
map.size());
134 maps_t::const_iterator it =
map.begin();
135 maps_t::const_iterator end =
map.end();
136 for (; it != end; ++it) {
137 out.push_back (it->second);
Helper to access contents of a stl map from python.
static void dump(const mapi_t &map)
static std::vector< int > values(const mapi_t &map)
std::map< std::string, int > mapi_t
std::map< std::string, std::string > maps_t
std::map< std::string, float > mapf_t
static bool equal(const mapi_t &m1, const mapi_t &m2)
static std::vector< std::string > keys(const mapi_t &map)