32 #include "dcmtk/config/osconfig.h" 34 #include "dcmtk/dcmnet/dicom.h" 35 #include "dcmtk/dcmdata/dcdatset.h" 36 #include "dcmtk/dcmdata/dcuid.h" 37 #include "dcmtk/dcmdata/dcdeftag.h" 38 #include "dcmtk/dcmqrdb/dcmqrdbi.h" 42 #define access my_access // Workaround to make Visual C++ Compiler happy! 92 #define PATIENT_LEVEL_STRING "PATIENT" 93 #define STUDY_LEVEL_STRING "STUDY" 94 #define SERIE_LEVEL_STRING "SERIES" 95 #define IMAGE_LEVEL_STRING "IMAGE" 102 #define AE_MAX_LENGTH 128 103 #define AS_MAX_LENGTH 32 104 #define AT_MAX_LENGTH 32 105 #define CS_MAX_LENGTH 128 106 #define DA_MAX_LENGTH 80 107 #define DS_MAX_LENGTH 128 108 #define DT_MAX_LENGTH 208 109 #define FL_MAX_LENGTH 32 110 #define FD_MAX_LENGTH 64 111 #define IS_MAX_LENGTH 96 112 #define LO_MAX_LENGTH 64 113 #define LT_MAX_LENGTH 10240 114 #define PN_MAX_LENGTH 64 115 #define SH_MAX_LENGTH 16 116 #define SL_MAX_LENGTH 32 117 #define SS_MAX_LENGTH 16 118 #define ST_MAX_LENGTH 1024 119 #define TM_MAX_LENGTH 128 120 #define UI_MAX_LENGTH 64 121 #define UL_MAX_LENGTH 32 122 #define US_MAX_LENGTH 16 123 #define CS_LABEL_MAX_LENGTH 16 124 #define DESCRIPTION_MAX_LENGTH 128 126 #define DBC_MAXSTRING 256 128 #define MAX_MAX_STUDIES DB_UpperMaxStudies 129 #define MAX_NUMBER_OF_IMAGES 10000 130 #define SIZEOF_IDXRECORD (sizeof (IdxRecord)) 131 #define SIZEOF_STUDYDESC (sizeof (StudyDescRecord) * MAX_MAX_STUDIES) 198 DB_KEY_TYPE keyAttr ;
199 DB_KEY_CLASS keyClass ;
203 : tag(t), level(l), keyAttr(kt), keyClass(kc) { }
211 DB_LEVEL queryLevel ;
212 char indexFilename[DBC_MAXSTRING+1] ;
213 char storageArea[DBC_MAXSTRING+1] ;
214 long maxBytesPerStudy ;
215 long maxStudiesAllowed ;
218 int NumberRemainOperations ;
219 DB_QUERY_CLASS rootLevel ;
224 , findRequestList(NULL)
225 , findResponseList(NULL)
226 , queryLevel(STUDY_LEVEL)
229 , maxBytesPerStudy(0)
230 , maxStudiesAllowed(0)
232 , moveCounterList(NULL)
233 , NumberRemainOperations(0)
234 , rootLevel(STUDY_ROOT)
247 char StudyInstanceUID [UI_MAX_LENGTH] ;
262 double RecordedDate ;
277 #define RECORDIDX_PatientBirthDate 0 278 #define RECORDIDX_PatientSex 1 279 #define RECORDIDX_PatientName 2 280 #define RECORDIDX_PatientID 3 281 #define RECORDIDX_PatientBirthTime 4 282 #define RECORDIDX_OtherPatientIDs 5 283 #define RECORDIDX_OtherPatientNames 6 284 #define RECORDIDX_EthnicGroup 7 285 #define RECORDIDX_NumberofPatientRelatedStudies 8 286 #define RECORDIDX_NumberofPatientRelatedSeries 9 287 #define RECORDIDX_NumberofPatientRelatedInstances 10 288 #define RECORDIDX_StudyDate 11 289 #define RECORDIDX_StudyTime 12 290 #define RECORDIDX_StudyID 13 291 #define RECORDIDX_StudyDescription 14 292 #define RECORDIDX_NameOfPhysiciansReadingStudy 15 293 #define RECORDIDX_AccessionNumber 16 294 #define RECORDIDX_ReferringPhysicianName 17 295 #define RECORDIDX_ProcedureDescription 18 296 #define RECORDIDX_AttendingPhysiciansName 19 297 #define RECORDIDX_StudyInstanceUID 20 298 #define RECORDIDX_OtherStudyNumbers 21 299 #define RECORDIDX_AdmittingDiagnosesDescription 22 300 #define RECORDIDX_PatientAge 23 301 #define RECORDIDX_PatientSize 24 302 #define RECORDIDX_PatientWeight 25 303 #define RECORDIDX_Occupation 26 304 #define RECORDIDX_NumberofStudyRelatedSeries 27 305 #define RECORDIDX_NumberofStudyRelatedInstances 28 306 #define RECORDIDX_SeriesNumber 29 307 #define RECORDIDX_SeriesInstanceUID 30 308 #define RECORDIDX_Modality 31 309 #define RECORDIDX_ImageNumber 32 310 #define RECORDIDX_SOPInstanceUID 33 311 #define RECORDIDX_SeriesDate 34 312 #define RECORDIDX_SeriesTime 35 313 #define RECORDIDX_SeriesDescription 36 314 #define RECORDIDX_ProtocolName 37 315 #define RECORDIDX_OperatorsName 38 316 #define RECORDIDX_PerformingPhysicianName 39 317 #define RECORDIDX_PresentationLabel 40 319 #define NBPARAMETERS 41 331 char filename [DBC_MAXSTRING+1] ;
332 char SOPClassUID [UI_MAX_LENGTH+1] ;
333 double RecordedDate ;
338 char PatientBirthDate [DA_MAX_LENGTH+1] ;
339 char PatientSex [CS_MAX_LENGTH+1] ;
340 char PatientName [PN_MAX_LENGTH+1] ;
341 char PatientID [LO_MAX_LENGTH+1] ;
342 char PatientBirthTime [TM_MAX_LENGTH+1] ;
343 char OtherPatientIDs [LO_MAX_LENGTH+1] ;
344 char OtherPatientNames [PN_MAX_LENGTH+1] ;
345 char EthnicGroup [SH_MAX_LENGTH+1] ;
346 char NumberofPatientRelatedStudies [IS_MAX_LENGTH+1] ;
347 char NumberofPatientRelatedSeries [IS_MAX_LENGTH+1] ;
348 char NumberofPatientRelatedInstances [IS_MAX_LENGTH+1] ;
350 char StudyDate [DA_MAX_LENGTH+1] ;
351 char StudyTime [TM_MAX_LENGTH+1] ;
352 char StudyID [CS_MAX_LENGTH+1] ;
353 char StudyDescription [LO_MAX_LENGTH+1] ;
354 char NameOfPhysiciansReadingStudy [PN_MAX_LENGTH+1] ;
356 char AccessionNumber [CS_MAX_LENGTH+1] ;
357 char ReferringPhysicianName [PN_MAX_LENGTH+1] ;
358 char ProcedureDescription [LO_MAX_LENGTH+1] ;
359 char AttendingPhysiciansName [PN_MAX_LENGTH+1] ;
360 char StudyInstanceUID [UI_MAX_LENGTH+1] ;
361 char OtherStudyNumbers [IS_MAX_LENGTH+1] ;
362 char AdmittingDiagnosesDescription [LO_MAX_LENGTH+1] ;
363 char PatientAge [AS_MAX_LENGTH+1] ;
364 char PatientSize [DS_MAX_LENGTH+1] ;
365 char PatientWeight [DS_MAX_LENGTH+1] ;
366 char Occupation [SH_MAX_LENGTH+1] ;
367 char NumberofStudyRelatedSeries [IS_MAX_LENGTH+1] ;
368 char NumberofStudyRelatedInstances [IS_MAX_LENGTH+1] ;
370 char SeriesNumber [IS_MAX_LENGTH+1] ;
371 char SeriesInstanceUID [UI_MAX_LENGTH+1] ;
372 char Modality [CS_MAX_LENGTH+1] ;
374 char ImageNumber [IS_MAX_LENGTH+1] ;
375 char SOPInstanceUID [UI_MAX_LENGTH+1] ;
377 char SeriesDate [DA_MAX_LENGTH+1] ;
378 char SeriesTime [TM_MAX_LENGTH+1] ;
379 char SeriesDescription [LO_MAX_LENGTH+1] ;
380 char ProtocolName [LO_MAX_LENGTH+1] ;
381 char OperatorsName [PN_MAX_LENGTH+1] ;
382 char PerformingPhysicianName [PN_MAX_LENGTH+1] ;
383 char PresentationLabel [CS_LABEL_MAX_LENGTH+1] ;
385 DVIFhierarchyStatus hstat;
388 char InstanceDescription [DESCRIPTION_MAX_LENGTH+1] ;
struct DB_ElementList * next
pointer to next in list
class maintaining a attribute tag (group and element number)
DB_SmallDcmElmt & operator=(const DB_SmallDcmElmt ©)
private undefined copy assignment operator
double LastRecordedDate
timestamp for last update of this study. Format: output of time(2) converted to double.
DB_ElementList()
default constructor
this struct defines the structure of each "Study Record" in the index.dat file maintained by this mod...
DcmTagKey XTag
attribute tag
int NumberofRegistratedImages
number of images of this study in the database
long StudySize
combined size (in bytes) of all images of this study in the database
Uint32 ValueLength
value length in bytes
this class provides a primitive interface for handling a list of flat DICOM elements, similar to DcmItem, but only for use within the database module
this class provides a primitive interface for handling a flat DICOM element, similar to DcmElement...
DB_SmallDcmElmt elem
current list element
this class manages an instance entry of the index file.
DB_SmallDcmElmt()
default constructor
char * PValueField
pointer to the value field