00001 /* 00002 * 00003 * Copyright (C) 1998-2005, OFFIS 00004 * 00005 * This software and supporting documentation were developed by 00006 * 00007 * Kuratorium OFFIS e.V. 00008 * Healthcare Information and Communication Systems 00009 * Escherweg 2 00010 * D-26121 Oldenburg, Germany 00011 * 00012 * THIS SOFTWARE IS MADE AVAILABLE, AS IS, AND OFFIS MAKES NO WARRANTY 00013 * REGARDING THE SOFTWARE, ITS PERFORMANCE, ITS MERCHANTABILITY OR 00014 * FITNESS FOR ANY PARTICULAR USE, FREEDOM FROM ANY COMPUTER DISEASES OR 00015 * ITS CONFORMITY TO ANY SPECIFICATION. THE ENTIRE RISK AS TO QUALITY AND 00016 * PERFORMANCE OF THE SOFTWARE IS WITH THE USER. 00017 * 00018 * Module: dcmpstat 00019 * 00020 * Author: Marco Eichelberg 00021 * 00022 * Purpose: 00023 * classes: DVPSReferencedImage 00024 * 00025 * Last Update: $Author: meichel $ 00026 * Update Date: $Date: 2005/12/08 16:03:59 $ 00027 * CVS/RCS Revision: $Revision: 1.9 $ 00028 * Status: $State: Exp $ 00029 * 00030 * CVS/RCS Log at end of file 00031 * 00032 */ 00033 00034 #ifndef __DVPSRI_H__ 00035 #define __DVPSRI_H__ 00036 00037 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ 00038 #include "dcmtk/dcmdata/dctk.h" 00039 00046 class DVPSReferencedImage 00047 { 00048 public: 00050 DVPSReferencedImage(); 00051 00053 DVPSReferencedImage(const DVPSReferencedImage& copy); 00054 00059 DVPSReferencedImage *clone() { return new DVPSReferencedImage(*this); } 00060 00062 virtual ~DVPSReferencedImage(); 00063 00073 OFCondition read(DcmItem &dset); 00074 00081 OFCondition write(DcmItem &dset); 00082 00092 OFBool validateSOPClassUID(OFString& sopclassuid); 00093 00097 void setSOPClassUID(const char *uid); 00098 00102 void setSOPInstanceUID(const char *uid); 00103 00108 void setFrameNumbers(const char *frames); 00109 00115 OFBool isSOPInstanceUID(const char *uid); 00116 00123 OFCondition getImageReference( 00124 OFString& sopclassUID, 00125 OFString& instanceUID, 00126 OFString& frames); 00127 00135 OFBool appliesToFrame(unsigned long frame); 00136 00142 OFBool appliesOnlyToFrame(unsigned long frame); 00143 00148 OFBool appliesToAllFrames(); 00149 00154 void removeFrameReference(unsigned long frame, unsigned long numberOfFrames); 00155 00161 void setLog(OFConsole *stream, OFBool verbMode, OFBool dbgMode); 00162 00163 private: 00164 00167 DVPSReferencedImage& operator=(const DVPSReferencedImage& source); 00168 00171 void flushCache(); 00174 void updateCache(); 00175 00177 DcmUniqueIdentifier referencedSOPClassUID; 00179 DcmUniqueIdentifier referencedSOPInstanceUID; 00181 DcmIntegerString referencedFrameNumber; 00183 Sint32 *frameCache; 00185 unsigned long frameCacheEntries; 00186 00189 OFConsole *logstream; 00190 00193 OFBool verboseMode; 00194 00197 OFBool debugMode; 00198 00199 }; 00200 00201 #endif 00202 00203 /* 00204 * $Log: dvpsri.h,v $ 00205 * Revision 1.9 2005/12/08 16:03:59 meichel 00206 * Changed include path schema for all DCMTK header files 00207 * 00208 * Revision 1.8 2001/09/26 15:36:14 meichel 00209 * Adapted dcmpstat to class OFCondition 00210 * 00211 * Revision 1.7 2001/06/01 15:50:20 meichel 00212 * Updated copyright header 00213 * 00214 * Revision 1.6 2000/06/02 16:00:50 meichel 00215 * Adapted all dcmpstat classes to use OFConsole for log and error output 00216 * 00217 * Revision 1.5 2000/03/08 16:28:55 meichel 00218 * Updated copyright header. 00219 * 00220 * Revision 1.4 1999/07/22 16:39:09 meichel 00221 * Adapted dcmpstat data structures and API to supplement 33 letter ballot text. 00222 * 00223 * Revision 1.3 1999/01/15 17:33:03 meichel 00224 * added methods to DVPresentationState allowing to access the image 00225 * references in the presentation state. Also added methods allowing to 00226 * get the width and height of the attached image. 00227 * 00228 * Revision 1.2 1998/12/14 16:10:32 meichel 00229 * Implemented Presentation State interface for graphic layers, 00230 * text and graphic annotations, presentation LUTs. 00231 * 00232 * Revision 1.1 1998/11/27 14:50:31 meichel 00233 * Initial Release. 00234 * 00235 * 00236 */