2 //-----------------------------------------------------------------------------
6 #ifdef GDCM_NO_ANSI_STRING_STREAM
8 # define ostringstream ostrstream
15 #include "gdcmDebug.h"
18 # define PUB_DICT_PATH "../Dicts/"
20 #define DICT_VR "dicomVR.dic"
22 //-----------------------------------------------------------------------------
23 // Constructor / Destructor
26 std::string filename=gdcmDictSet::BuildDictPath() + std::string(DICT_VR);
27 std::ifstream from(filename.c_str());
28 dbg.Error(!from, "gdcmVR::gdcmVR: can't open dictionary",filename.c_str());
37 from.getline(buff, 1024, ' ');
40 from.getline(buff, 1024, ';');
44 from.getline(buff, 1024, '\n');
58 //-----------------------------------------------------------------------------
63 * @param os The output stream to be written to.
65 void gdcmVR::Print(std::ostream &os)
69 for (VRHT::iterator it = vr.begin(); it != vr.end(); ++it)
71 s << "VR : "<<it->first<<" = "<<it->second<<std::endl;
76 //-----------------------------------------------------------------------------
80 * \brief Get the count for an element
81 * @param key key to count
83 int gdcmVR::Count(VRKey key)
88 //-----------------------------------------------------------------------------
91 //-----------------------------------------------------------------------------
94 //-----------------------------------------------------------------------------