dcmsr/include/dsrtncsr.h

00001 /* 00002 * 00003 * Copyright (C) 2000-2003, 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: DSRTreeNodeCursor 00024 * 00025 * Last Update: $Author: joergr $ 00026 * Update Date: $Date: 2003/08/07 12:55:46 $ 00027 * CVS/RCS Revision: $Revision: 1.10 $ 00028 * Status: $State: Exp $ 00029 * 00030 * CVS/RCS Log at end of file 00031 * 00032 */ 00033 00034 00035 #ifndef DSRTNCSR_H 00036 #define DSRTNCSR_H 00037 00038 #include "osconfig.h" /* make sure OS specific configuration is included first */ 00039 00040 #include "ofstring.h" 00041 #include "ofstack.h" 00042 #include "oflist.h" 00043 00044 00045 /*-----------------------* 00046 * forward declaration * 00047 *-----------------------*/ 00048 00049 class DSRTreeNode; 00050 00051 00052 /*-------------------* 00053 * type definition * 00054 *-------------------*/ 00055 00056 // this typedef is needed to avoid a warning on Sun CC 2.0.1 00057 typedef DSRTreeNode *DSRTreeNodePointer; 00058 00059 00060 /*---------------------* 00061 * class declaration * 00062 *---------------------*/ 00063 00066 class DSRTreeNodeCursor 00067 { 00068 00069 public: 00070 00073 DSRTreeNodeCursor(); 00074 00078 DSRTreeNodeCursor(const DSRTreeNodeCursor &cursor); 00079 00083 DSRTreeNodeCursor(DSRTreeNode *node); 00084 00087 virtual ~DSRTreeNodeCursor(); 00088 00093 DSRTreeNodeCursor &operator=(const DSRTreeNodeCursor &cursor); 00094 00099 DSRTreeNodeCursor &operator=(DSRTreeNode *node); 00100 00103 virtual void clear(); 00104 00108 virtual OFBool isValid() const; 00109 00113 inline DSRTreeNode *getNode() const 00114 { 00115 return NodeCursor; 00116 } 00117 00122 const DSRTreeNode *getParentNode(); 00123 00128 const DSRTreeNode *getNextNode() const; 00129 00133 size_t gotoPrevious(); 00134 00138 size_t gotoNext(); 00139 00143 size_t goUp(); 00144 00148 size_t goDown(); 00149 00154 size_t iterate(); 00155 00160 size_t gotoNode(const size_t searchID); 00161 00169 size_t gotoNode(const OFString &position, 00170 const char separator = '.'); 00171 00177 size_t getNodeID() const; 00178 00183 size_t getLevel() const; 00184 00196 const OFString &getPosition(OFString &position, 00197 const char separator = '.') const; 00198 00199 00200 protected: 00201 00204 void clearNodeCursorStack(); 00205 00211 size_t setCursor(DSRTreeNode *node); 00212 00214 DSRTreeNode *NodeCursor; 00216 OFStack< DSRTreeNodePointer > NodeCursorStack; 00217 00219 size_t Position; 00221 OFList<size_t> PositionList; 00222 }; 00223 00224 00225 #endif 00226 00227 00228 /* 00229 * CVS/RCS Log: 00230 * $Log: dsrtncsr.h,v $ 00231 * Revision 1.10 2003/08/07 12:55:46 joergr 00232 * Updated documentation to get rid of doxygen warnings. 00233 * 00234 * Revision 1.9 2001/12/18 09:55:06 meichel 00235 * Introduced typedef to avoid warning on Sun CC 2.0.1 00236 * 00237 * Revision 1.8 2001/03/28 09:06:56 joergr 00238 * Fixed bug in cycle/loop detection "algorithm". 00239 * 00240 * Revision 1.7 2000/11/09 20:32:08 joergr 00241 * Added support for non-ASCII characters in HTML 3.2 (use numeric value). 00242 * 00243 * Revision 1.6 2000/11/07 18:14:31 joergr 00244 * Enhanced support for by-reference relationships. 00245 * 00246 * Revision 1.5 2000/10/26 14:20:49 joergr 00247 * Generalized routine to get and search for position strings ("1.2.3"). 00248 * 00249 * Revision 1.4 2000/10/18 17:09:06 joergr 00250 * Made some functions inline. 00251 * 00252 * Revision 1.3 2000/10/16 16:31:08 joergr 00253 * Updated comments. 00254 * 00255 * Revision 1.2 2000/10/16 11:57:00 joergr 00256 * Added doc++ comments. 00257 * 00258 * Revision 1.1 2000/10/13 07:49:34 joergr 00259 * Added new module 'dcmsr' providing access to DICOM structured reporting 00260 * documents (supplement 23). Doc++ documentation not yet completed. 00261 * 00262 * 00263 */


Generated on 4 Nov 2004 for OFFIS DCMTK Version 3.5.3 by Doxygen 1.3.8