00001 /* 00002 * 00003 * Copyright (C) 2000-2010, OFFIS e.V. 00004 * All rights reserved. See COPYRIGHT file for details. 00005 * 00006 * This software and supporting documentation were developed by 00007 * 00008 * OFFIS e.V. 00009 * R&D Division Health 00010 * Escherweg 2 00011 * D-26121 Oldenburg, Germany 00012 * 00013 * 00014 * Module: dcmsr 00015 * 00016 * Author: Joerg Riesmeier 00017 * 00018 * Purpose: 00019 * classes: DSRSpatialCoordinatesValue 00020 * 00021 * Last Update: $Author: joergr $ 00022 * Update Date: $Date: 2010-10-14 13:16:33 $ 00023 * CVS/RCS Revision: $Revision: 1.15 $ 00024 * Status: $State: Exp $ 00025 * 00026 * CVS/RCS Log at end of file 00027 * 00028 */ 00029 00030 00031 #ifndef DSRSCOVL_H 00032 #define DSRSCOVL_H 00033 00034 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ 00035 00036 #include "dcmtk/dcmsr/dsrtypes.h" 00037 #include "dcmtk/dcmsr/dsrscogr.h" 00038 00039 00040 /*---------------------* 00041 * class declaration * 00042 *---------------------*/ 00043 00046 class DSRSpatialCoordinatesValue 00047 { 00048 // allow access to getValuePtr() 00049 friend class DSRContentItem; 00050 00051 public: 00052 00055 DSRSpatialCoordinatesValue(); 00056 00060 DSRSpatialCoordinatesValue(const DSRTypes::E_GraphicType graphicType); 00061 00065 DSRSpatialCoordinatesValue(const DSRSpatialCoordinatesValue &coordinatesValue); 00066 00069 virtual ~DSRSpatialCoordinatesValue(); 00070 00076 DSRSpatialCoordinatesValue &operator=(const DSRSpatialCoordinatesValue &coordinatesValue); 00077 00082 virtual void clear(); 00083 00089 virtual OFBool isValid() const; 00090 00097 virtual OFBool isShort(const size_t flags) const; 00098 00105 virtual OFCondition print(STD_NAMESPACE ostream &stream, 00106 const size_t flags) const; 00107 00112 virtual OFCondition read(DcmItem &dataset); 00113 00118 virtual OFCondition write(DcmItem &dataset) const; 00119 00125 virtual OFCondition readXML(const DSRXMLDocument &doc, 00126 DSRXMLCursor cursor); 00127 00133 virtual OFCondition writeXML(STD_NAMESPACE ostream &stream, 00134 const size_t flags) const; 00135 00144 virtual OFCondition renderHTML(STD_NAMESPACE ostream &docStream, 00145 STD_NAMESPACE ostream &annexStream, 00146 size_t &annexNumber, 00147 const size_t flags) const; 00148 00152 inline const DSRSpatialCoordinatesValue &getValue() const 00153 { 00154 return *this; 00155 } 00156 00162 inline DSRTypes::E_GraphicType getGraphicType() const 00163 { 00164 return GraphicType; 00165 } 00166 00173 OFCondition setGraphicType(const DSRTypes::E_GraphicType graphicType); 00174 00179 OFCondition getValue(DSRSpatialCoordinatesValue &coordinatesValue) const; 00180 00187 OFCondition setValue(const DSRSpatialCoordinatesValue &coordinatesValue); 00188 00194 inline DSRGraphicDataList &getGraphicDataList() 00195 { 00196 return GraphicDataList; 00197 } 00198 00199 00200 protected: 00201 00205 inline DSRSpatialCoordinatesValue *getValuePtr() 00206 { 00207 return this; 00208 } 00209 00218 OFBool checkData(const DSRTypes::E_GraphicType graphicType, 00219 const DSRGraphicDataList &graphicDataList) const; 00220 00221 00222 private: 00223 00225 DSRTypes::E_GraphicType GraphicType; 00227 DSRGraphicDataList GraphicDataList; 00228 }; 00229 00230 00231 #endif 00232 00233 00234 /* 00235 * CVS/RCS Log: 00236 * $Log: dsrscovl.h,v $ 00237 * Revision 1.15 2010-10-14 13:16:33 joergr 00238 * Updated copyright header. Added reference to COPYRIGHT file. 00239 * 00240 * Revision 1.14 2010-09-28 14:03:37 joergr 00241 * Updated comment on the requirements for POLYLINE according to CP-233. 00242 * 00243 * Revision 1.13 2009-10-13 14:57:50 uli 00244 * Switched to logging mechanism provided by the "new" oflog module. 00245 * 00246 * Revision 1.12 2007-11-15 16:33:30 joergr 00247 * Added support for output in XHTML 1.1 format. 00248 * 00249 * Revision 1.11 2006/08/15 16:40:03 meichel 00250 * Updated the code in module dcmsr to correctly compile when 00251 * all standard C++ classes remain in namespace std. 00252 * 00253 * Revision 1.10 2005/12/08 16:05:17 meichel 00254 * Changed include path schema for all DCMTK header files 00255 * 00256 * Revision 1.9 2003/08/07 18:01:42 joergr 00257 * Removed libxml dependency from header files. 00258 * 00259 * Revision 1.8 2003/08/07 12:47:10 joergr 00260 * Added readXML functionality. 00261 * 00262 * Revision 1.7 2001/09/26 13:04:11 meichel 00263 * Adapted dcmsr to class OFCondition 00264 * 00265 * Revision 1.6 2001/06/01 15:51:03 meichel 00266 * Updated copyright header 00267 * 00268 * Revision 1.5 2000/11/06 11:18:09 joergr 00269 * Moved some protected methods to public part. 00270 * 00271 * Revision 1.4 2000/11/01 16:23:24 joergr 00272 * Added support for conversion to XML. 00273 * 00274 * Revision 1.3 2000/10/18 17:07:30 joergr 00275 * Added methods allowing direct access to certain content item values. 00276 * Added doc++ comments. 00277 * Made some functions inline. 00278 * 00279 * Revision 1.2 2000/10/16 11:57:23 joergr 00280 * Added methods allowing direct access to certain content item values. 00281 * 00282 * Revision 1.1 2000/10/13 07:49:32 joergr 00283 * Added new module 'dcmsr' providing access to DICOM structured reporting 00284 * documents (supplement 23). Doc++ documentation not yet completed. 00285 * 00286 * 00287 */