6 int TestHash( int, char * [] ) {
8 typedef std::map<std::string, char*> dict;
11 dict::iterator im = tb1.find("00380010");
12 tb1["00100010"] = "Patient Name";
13 tb1["7fe00010"] = "Pixel Data";
14 tb1["50000010"] = "Number of points";
15 tb1["00380010"] = "Admission ID";
17 std::cout << "Traversal of dictionary (note the proper ordering on key)." << std::endl;
18 for ( im = tb1.begin(); im != tb1.end(); ++im )
19 std::cout << " \"" << im->first << "\" = " << im->second << std::endl;
20 std::cout << "End of dictionary." << std::endl;
22 std::cout << "Find request on key 00380010" << std::endl;
23 im = tb1.find("00380010");
24 std::cout << " \"" << im->first << "\" = " << im->second << std::endl;
27 std::cout.setf(std::ios::hex);
28 std::cout << i << std::endl;
29 std::cout.setf(std::ios::dec);
30 std::cout << i << std::endl;
33 //http://www.developer.com/net/cplus/article.php/10919_2119781_3
35 // dommage que ca ne marche pas ...