X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Testing%2FTestDictGroupName.cxx;h=daa6f700c44948a6077a34166b2526fa33043eb8;hb=HEAD;hp=cc74a79f864efabbdebcce1ec22e620f95a8b2bf;hpb=99527f7d2edc2714942c0837cb56ff333b9fbb92;p=gdcm.git diff --git a/Testing/TestDictGroupName.cxx b/Testing/TestDictGroupName.cxx index cc74a79f..daa6f700 100644 --- a/Testing/TestDictGroupName.cxx +++ b/Testing/TestDictGroupName.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: TestDictGroupName.cxx,v $ Language: C++ - Date: $Date: 2005/07/08 13:39:57 $ - Version: $Revision: 1.3 $ + Date: $Date: 2007/05/23 14:18:06 $ + Version: $Revision: 1.5 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -21,10 +21,10 @@ #include -int CompareDictGroupName(gdcm::DictGroupName &groupName, +int CompareDictGroupName(GDCM_NAME_SPACE::DictGroupName *groupName, uint16_t group,std::string ref) { - std::string val = groupName.GetName(group); + std::string val = groupName->GetName(group); std::cout << "Group : 0x" << std::hex << std::setw(4) << group << std::dec << " : " << val << " - " << (bool)(val==ref) << std::endl; @@ -34,15 +34,17 @@ int CompareDictGroupName(gdcm::DictGroupName &groupName, int TestDictGroupName(int , char *[]) { - gdcm::DictGroupName groupName; - groupName.Print( std::cout ); + GDCM_NAME_SPACE::DictGroupName *groupName = GDCM_NAME_SPACE::DictGroupName::New(); + groupName->Print( std::cout ); int ret = 0; std::cout << std::endl; ret += CompareDictGroupName(groupName,0x0002,"Meta Elements"); ret += CompareDictGroupName(groupName,0x7fe0,"Pixels"); - ret += CompareDictGroupName(groupName,0x0007,gdcm::GDCM_UNFOUND); + ret += CompareDictGroupName(groupName,0x0007,GDCM_NAME_SPACE::GDCM_UNFOUND); + + groupName->Delete(); return ret; }