#include <gdcmValidator.h>
Inheritance diagram for GDCM_NAME_SPACE::Validator:
Public Member Functions | |
void | SetInput (ElementSet *input) |
void | Delete () |
Delete the object. | |
void | Register () |
Register the object. | |
void | Unregister () |
Unregister the object. | |
const unsigned long & | GetRefCount () const |
Get the reference counting. | |
virtual void | Print (std::ostream &=std::cout, std::string const &="") |
Printer. | |
void | SetPrintLevel (int level) |
Sets the print level for the Dicom Header Elements. | |
int | GetPrintLevel () |
Gets the print level for the Dicom Entries. | |
Static Public Member Functions | |
static Validator * | New () |
Constructs a Validator with a RefCounter. | |
Protected Member Functions | |
Validator () | |
Constructor. | |
~Validator () | |
Canonical Destructor. | |
Protected Attributes | |
int | PrintLevel |
Amount of printed details for each Dicom Entries : 0 : stands for the least detail level. | |
Private Member Functions | |
gdcmTypeMacro (Validator) |
Definition at line 30 of file gdcmValidator.h.
|
Constructor.
Definition at line 33 of file gdcmValidator.cxx.
|
|
Canonical Destructor.
Definition at line 37 of file gdcmValidator.cxx.
|
|
|
|
|
Gets the print level for the Dicom Entries.
Definition at line 50 of file gdcmBase.h. 00050 { return PrintLevel; }
|
|
Get the reference counting.
Definition at line 59 of file gdcmRefCounter.h. 00060 { 00061 return RefCount; 00062 }
|
|
Constructs a Validator with a RefCounter.
Definition at line 37 of file gdcmValidator.h. 00037 {return new Validator();}
|
|
|
Register the object.
Definition at line 46 of file gdcmRefCounter.h. Referenced by GDCM_NAME_SPACE::SQItem::AddEntry(), GDCM_NAME_SPACE::SeqEntry::AddSQItem(), GDCM_NAME_SPACE::SeqEntry::Copy(), GDCM_NAME_SPACE::DicomDir::Copy(), GDCM_NAME_SPACE::FileHelper::FileHelper(), GDCM_NAME_SPACE::DocEntrySet::GetDictEntry(), GDCM_NAME_SPACE::DocEntry::GetName(), GDCM_NAME_SPACE::DocEntry::GetVM(), GDCM_NAME_SPACE::DocEntrySet::InsertEntryString(), GDCM_NAME_SPACE::CommandManager::InSetCommand(), GDCM_NAME_SPACE::DocEntryArchive::Push(), and GDCM_NAME_SPACE::SeqEntry::SetDelimitationItem(). 00046 { RefCount++; }
|
|
Definition at line 69 of file gdcmValidator.cxx. References GDCM_NAME_SPACE::CheckVM(), GDCM_NAME_SPACE::GDCM_UNKNOWN, GDCM_NAME_SPACE::ElementSet::GetFirstEntry(), GDCM_NAME_SPACE::DocEntry::GetKey(), and GDCM_NAME_SPACE::ElementSet::GetNextEntry(). 00070 { 00071 00072 DocEntry *d; 00073 /* 00074 // First stage to check group length 00075 GroupHT grHT; 00076 d=input->GetFirstEntry(); 00077 while(d) 00078 { 00079 grHT[d->GetGroup()] = 0; 00080 d=input->GetNextEntry(); 00081 } 00082 for (GroupHT::iterator it = grHT.begin(); it != grHT.end(); ++it) 00083 { 00084 std::cout << std::hex << it->first << std::endl; 00085 } 00086 */ 00087 00088 // berk for now SetInput do two things at the same time 00089 d=input->GetFirstEntry(); 00090 if (!d) 00091 { 00092 std::cout << "No Entry found" << std::endl; 00093 return; 00094 } 00095 while(d) 00096 { 00097 if ( DataEntry *v = dynamic_cast<DataEntry *>(d) ) 00098 { 00099 if ( v->GetVM() != GDCM_NAME_SPACE::GDCM_UNKNOWN ) 00100 if ( !CheckVM(v) ) 00101 { 00102 if (v->GetVM() == "FIXME" ) 00103 std::cout << "For Tag " << v->GetKey() << " VM = [" 00104 << v->GetVM() << "]" << std::endl; 00105 00106 std::cout << "Tag (" << v->GetKey() 00107 << ")-> [" << v->GetName() << "] VR :" << v->GetVR() 00108 << " contains an illegal VM. Expected VM :[" 00109 << v->GetVM() << "], value [" << v->GetString() << "]" 00110 << std::endl; 00111 } 00112 00113 if ( v->GetReadLength() % 2 ) 00114 { 00115 std::cout << "Tag (" << v->GetKey() 00116 << ")-> [" << v->GetName() << "] has an uneven length :" 00117 << v->GetReadLength() 00118 << " [" << v->GetString() << "] " 00119 << std::endl; 00120 } 00121 } 00122 else 00123 { 00124 // We skip pb of SQ recursive exploration 00125 } 00126 d=input->GetNextEntry(); 00127 } 00128 }
|
|
Sets the print level for the Dicom Header Elements.
Definition at line 47 of file gdcmBase.h. Referenced by GDCM_NAME_SPACE::FileHelper::Print(), and GDCM_NAME_SPACE::DicomDir::Print(). 00047 { PrintLevel = level; }
|
|
Unregister the object.
Definition at line 50 of file gdcmRefCounter.h. Referenced by GDCM_NAME_SPACE::Document::ReadNextDocEntry(), GDCM_NAME_SPACE::SQItem::RemoveEntry(), GDCM_NAME_SPACE::ElementSet::RemoveEntry(), and GDCM_NAME_SPACE::FileHelper::~FileHelper(). 00051 { 00052 //std::cout <<"================Unreg " << typeid(*this).name() << std::endl; 00053 RefCount--; 00054 if(RefCount<=0) 00055 delete this; 00056 }
|
|
Amount of printed details for each Dicom Entries : 0 : stands for the least detail level.
Definition at line 55 of file gdcmBase.h. Referenced by GDCM_NAME_SPACE::SeqEntry::Print(), GDCM_NAME_SPACE::FileHelper::Print(), GDCM_NAME_SPACE::ElementSet::Print(), GDCM_NAME_SPACE::DocEntry::Print(), GDCM_NAME_SPACE::DictEntry::Print(), GDCM_NAME_SPACE::DicomDirStudy::Print(), GDCM_NAME_SPACE::DicomDirSerie::Print(), GDCM_NAME_SPACE::DicomDirPatient::Print(), GDCM_NAME_SPACE::DicomDirMeta::Print(), GDCM_NAME_SPACE::DicomDir::Print(), and GDCM_NAME_SPACE::DataEntry::Print(). |