dcmsr/include/dcmtk/dcmsr/dsrstrvl.h

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: DSRStringValue
00020  *
00021  *  Last Update:      $Author: joergr $
00022  *  Update Date:      $Date: 2010-10-14 13:16:33 $
00023  *  CVS/RCS Revision: $Revision: 1.16 $
00024  *  Status:           $State: Exp $
00025  *
00026  *  CVS/RCS Log at end of file
00027  *
00028  */
00029 
00030 
00031 #ifndef DSRSTRVL_H
00032 #define DSRSTRVL_H
00033 
00034 #include "dcmtk/config/osconfig.h"   /* make sure OS specific configuration is included first */
00035 
00036 #include "dcmtk/dcmsr/dsrtypes.h"
00037 
00038 #include "dcmtk/ofstd/ofstring.h"
00039 
00040 
00041 /*---------------------*
00042  *  class declaration  *
00043  *---------------------*/
00044 
00047 class DSRStringValue
00048 {
00049 
00050   public:
00051 
00054     DSRStringValue();
00055 
00060     DSRStringValue(const OFString &stringValue);
00061 
00065     DSRStringValue(const DSRStringValue &stringValue);
00066 
00069     virtual ~DSRStringValue();
00070 
00075     DSRStringValue &operator=(const DSRStringValue &stringValue);
00076 
00080     virtual void clear();
00081 
00086     virtual OFBool isValid() const;
00087 
00098     void print(STD_NAMESPACE ostream &stream,
00099                const size_t maxLength = 0) const;
00100 
00108     OFCondition read(DcmItem &dataset,
00109                      const DcmTagKey &tagKey);
00110 
00116     OFCondition write(DcmItem &dataset,
00117                       const DcmTagKey &tagKey) const;
00118 
00125     OFCondition readXML(const DSRXMLDocument &doc,
00126                         DSRXMLCursor cursor,
00127                         const OFBool encoding = OFFalse);
00128 
00134     OFCondition renderHTML(STD_NAMESPACE ostream &docStream,
00135                            const size_t flags) const;
00136 
00140     inline const OFString &getValue() const
00141     {
00142         return Value;
00143     }
00144 
00152     OFCondition setValue(const OFString &stringValue);
00153 
00154 
00155   protected:
00156 
00164     virtual OFBool checkValue(const OFString &stringValue) const;
00165 
00166 
00167   private:
00168 
00170     OFString Value;
00171 };
00172 
00173 
00174 #endif
00175 
00176 
00177 /*
00178  *  CVS/RCS Log:
00179  *  $Log: dsrstrvl.h,v $
00180  *  Revision 1.16  2010-10-14 13:16:33  joergr
00181  *  Updated copyright header. Added reference to COPYRIGHT file.
00182  *
00183  *  Revision 1.15  2009-10-13 14:57:50  uli
00184  *  Switched to logging mechanism provided by the "new" oflog module.
00185  *
00186  *  Revision 1.14  2007-11-15 16:33:30  joergr
00187  *  Added support for output in XHTML 1.1 format.
00188  *
00189  *  Revision 1.13  2006/08/15 16:40:03  meichel
00190  *  Updated the code in module dcmsr to correctly compile when
00191  *    all standard C++ classes remain in namespace std.
00192  *
00193  *  Revision 1.12  2006/05/11 09:18:21  joergr
00194  *  Moved containsExtendedCharacters() from dcmsr to dcmdata module.
00195  *
00196  *  Revision 1.11  2005/12/08 16:05:19  meichel
00197  *  Changed include path schema for all DCMTK header files
00198  *
00199  *  Revision 1.10  2004/11/22 16:39:09  meichel
00200  *  Added method that checks if the SR document contains non-ASCII characters
00201  *    in any of the strings affected by SpecificCharacterSet.
00202  *
00203  *  Revision 1.9  2003/08/07 18:01:42  joergr
00204  *  Removed libxml dependency from header files.
00205  *
00206  *  Revision 1.8  2003/08/07 12:50:44  joergr
00207  *  Added readXML functionality.
00208  *
00209  *  Revision 1.7  2001/09/26 13:04:11  meichel
00210  *  Adapted dcmsr to class OFCondition
00211  *
00212  *  Revision 1.6  2001/06/01 15:51:03  meichel
00213  *  Updated copyright header
00214  *
00215  *  Revision 1.5  2000/11/06 11:18:48  joergr
00216  *  Moved some protected methods to public part.
00217  *
00218  *  Revision 1.4  2000/11/01 16:23:25  joergr
00219  *  Added support for conversion to XML.
00220  *
00221  *  Revision 1.3  2000/10/23 15:12:55  joergr
00222  *  Added/updated doc++ comments.
00223  *
00224  *  Revision 1.2  2000/10/18 17:08:11  joergr
00225  *  Added read and write methods.
00226  *
00227  *  Revision 1.1  2000/10/13 07:49:32  joergr
00228  *  Added new module 'dcmsr' providing access to DICOM structured reporting
00229  *  documents (supplement 23).  Doc++ documentation not yet completed.
00230  *
00231  *
00232  */


Generated on 6 Jan 2011 for OFFIS DCMTK Version 3.6.0 by Doxygen 1.5.1