Helper class to deal with stl container. More...
#include <MC_helper_stl.hpp>
Static Public Member Functions | |
| template<class TA , class TB > | |
| static std::vector< TB > | map_arg2_to_vector (const std::map< TA, TB > &m) |
| convert the argument2 of a map to a vector | |
| template<class TA , class TB > | |
| static std::map< TB, TA > | reverse_map (const std::map< TA, TB > &m) |
| reverse a map from map<A,B> going to map<B,A> | |
Helper class to deal with stl container.
Definition at line 29 of file MC_helper_stl.hpp.
| static std::vector<TB> mesh_conv::MC_helper_stl::map_arg2_to_vector | ( | const std::map< TA, TB > & | m | ) | [inline, static] |
convert the argument2 of a map to a vector
Definition at line 35 of file MC_helper_stl.hpp.
| static std::map<TB,TA> mesh_conv::MC_helper_stl::reverse_map | ( | const std::map< TA, TB > & | m | ) | [inline, static] |
reverse a map from map<A,B> going to map<B,A>
Definition at line 48 of file MC_helper_stl.hpp.
Referenced by mesh_conv::MC_mesh_index_vector::subdivide_mixed_mid_edge().
00049 { 00050 std::map <TB,TA> reversed; 00051 typename std::map <TA,TB> :: const_iterator it=m.begin(); 00052 typename std::map <TA,TB> :: const_iterator it_end=m.end(); 00053 for(;it!=it_end;++it) 00054 reversed.insert(std::make_pair(it->second,it->first)); 00055 return reversed; 00056 }

1.6.1