00001 /* 00002 * 00003 * Copyright (C) 2000-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: dcmsr 00019 * 00020 * Author: Joerg Riesmeier 00021 * 00022 * Purpose: 00023 * classes: DSRTemporalCoordinatesValue 00024 * 00025 * Last Update: $Author: meichel $ 00026 * Update Date: $Date: 2005/12/08 16:05:24 $ 00027 * CVS/RCS Revision: $Revision: 1.8 $ 00028 * Status: $State: Exp $ 00029 * 00030 * CVS/RCS Log at end of file 00031 * 00032 */ 00033 00034 00035 #ifndef DSRTCOVL_H 00036 #define DSRTCOVL_H 00037 00038 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ 00039 00040 #include "dcmtk/dcmsr/dsrtypes.h" 00041 #include "dcmtk/dcmsr/dsrtcodt.h" 00042 #include "dcmtk/dcmsr/dsrtcosp.h" 00043 #include "dcmtk/dcmsr/dsrtcoto.h" 00044 00045 00046 /*---------------------* 00047 * class declaration * 00048 *---------------------*/ 00049 00052 class DSRTemporalCoordinatesValue 00053 { 00054 // allow access to getValuePtr() 00055 friend class DSRContentItem; 00056 00057 public: 00058 00061 DSRTemporalCoordinatesValue(); 00062 00066 DSRTemporalCoordinatesValue(const DSRTypes::E_TemporalRangeType temporalRangeType); 00067 00071 DSRTemporalCoordinatesValue(const DSRTemporalCoordinatesValue &coordinatesValue); 00072 00075 virtual ~DSRTemporalCoordinatesValue(); 00076 00082 DSRTemporalCoordinatesValue &operator=(const DSRTemporalCoordinatesValue &coordinatesValue); 00083 00088 virtual void clear(); 00089 00095 virtual OFBool isValid() const; 00096 00103 virtual OFBool isShort(const size_t flags) const; 00104 00112 virtual OFCondition print(ostream &stream, 00113 const size_t flags) const; 00114 00120 virtual OFCondition readXML(const DSRXMLDocument &doc, 00121 DSRXMLCursor cursor); 00122 00129 virtual OFCondition writeXML(ostream &stream, 00130 const size_t flags, 00131 OFConsole *logStream) const; 00132 00142 virtual OFCondition renderHTML(ostream &docStream, 00143 ostream &annexStream, 00144 size_t &annexNumber, 00145 const size_t flags, 00146 OFConsole *logStream) const; 00147 00151 inline const DSRTemporalCoordinatesValue &getValue() const 00152 { 00153 return *this; 00154 } 00155 00160 OFCondition getValue(DSRTemporalCoordinatesValue &coordinatesValue) const; 00161 00169 OFCondition setValue(const DSRTemporalCoordinatesValue &coordinatesValue); 00170 00175 inline DSRTypes::E_TemporalRangeType getTemporalRangeType() const 00176 { 00177 return TemporalRangeType; 00178 } 00179 00185 OFCondition setTemporalRangeType(const DSRTypes::E_TemporalRangeType temporalRangeType); 00186 00190 inline DSRReferencedDatetimeList &getDatetimeList() 00191 { 00192 return DatetimeList; 00193 } 00194 00198 inline DSRReferencedSamplePositionList &getSamplePositionList() 00199 { 00200 return SamplePositionList; 00201 } 00202 00206 inline DSRReferencedTimeOffsetList &getTimeOffsetList() 00207 { 00208 return TimeOffsetList; 00209 } 00210 00211 00212 protected: 00213 00217 inline DSRTemporalCoordinatesValue *getValuePtr() 00218 { 00219 return this; 00220 } 00221 00229 virtual OFCondition read(DcmItem &dataset, 00230 OFConsole *logStream); 00231 00238 virtual OFCondition write(DcmItem &dataset, 00239 OFConsole *logStream) const; 00240 00252 OFBool checkData(const DSRTypes::E_TemporalRangeType temporalRangeType, 00253 const DSRReferencedSamplePositionList &samplePositionList, 00254 const DSRReferencedTimeOffsetList &timeOffsetList, 00255 const DSRReferencedDatetimeList &datetimeList, 00256 OFConsole *logStream = NULL) const; 00257 00258 private: 00259 00261 DSRTypes::E_TemporalRangeType TemporalRangeType; 00262 00264 DSRReferencedSamplePositionList SamplePositionList; 00266 DSRReferencedTimeOffsetList TimeOffsetList; 00268 DSRReferencedDatetimeList DatetimeList; 00269 }; 00270 00271 00272 #endif 00273 00274 00275 /* 00276 * CVS/RCS Log: 00277 * $Log: dsrtcovl.h,v $ 00278 * Revision 1.8 2005/12/08 16:05:24 meichel 00279 * Changed include path schema for all DCMTK header files 00280 * 00281 * Revision 1.7 2003/08/07 18:01:42 joergr 00282 * Removed libxml dependency from header files. 00283 * 00284 * Revision 1.6 2003/08/07 12:53:13 joergr 00285 * Added readXML functionality. 00286 * 00287 * Revision 1.5 2001/09/26 13:04:12 meichel 00288 * Adapted dcmsr to class OFCondition 00289 * 00290 * Revision 1.4 2001/06/01 15:51:05 meichel 00291 * Updated copyright header 00292 * 00293 * Revision 1.3 2000/11/06 11:20:32 joergr 00294 * Moved some protected methods to public part. 00295 * 00296 * Revision 1.2 2000/11/01 16:23:26 joergr 00297 * Added support for conversion to XML. 00298 * 00299 * Revision 1.1 2000/10/26 14:23:26 joergr 00300 * Added support for TCOORD content item. 00301 * 00302 * 00303 */