00001 /* 00002 * 00003 * Copyright (C) 1994-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: dcmdata 00019 * 00020 * Author: Gerd Ehlers, Andreas Barth 00021 * 00022 * Purpose: Interface of class DcmIntegerString 00023 * 00024 * Last Update: $Author: meichel $ 00025 * Update Date: $Date: 2005/12/08 16:29:00 $ 00026 * Source File: $Source: /share/dicom/cvs-depot/dcmtk/dcmdata/include/dcmtk/dcmdata/dcvris.h,v $ 00027 * CVS/RCS Revision: $Revision: 1.15 $ 00028 * Status: $State: Exp $ 00029 * 00030 * CVS/RCS Log at end of file 00031 * 00032 */ 00033 00034 #ifndef DCVRIS_H 00035 #define DCVRIS_H 00036 00037 #include "dcmtk/config/osconfig.h" /* make sure OS specific configuration is included first */ 00038 00039 #include "dcmtk/dcmdata/dctypes.h" 00040 #include "dcmtk/dcmdata/dcbytstr.h" 00041 00042 00045 class DcmIntegerString 00046 : public DcmByteString 00047 { 00048 00049 public: 00050 00056 DcmIntegerString(const DcmTag &tag, 00057 const Uint32 len = 0); 00058 00062 DcmIntegerString(const DcmIntegerString &old); 00063 00066 virtual ~DcmIntegerString(); 00067 00072 DcmIntegerString &operator=(const DcmIntegerString &obj); 00073 00077 virtual DcmObject *clone() const 00078 { 00079 return new DcmIntegerString(*this); 00080 } 00081 00085 virtual DcmEVR ident() const; 00086 00092 virtual OFCondition getSint32(Sint32 &sintVal, 00093 const unsigned long pos = 0); 00094 00101 virtual OFCondition getOFString(OFString &stringVal, 00102 const unsigned long pos, 00103 OFBool normalize = OFTrue); 00104 }; 00105 00106 00107 #endif // DCVRIS_H 00108 00109 00110 /* 00111 ** CVS/RCS Log: 00112 ** $Log: dcvris.h,v $ 00113 ** Revision 1.15 2005/12/08 16:29:00 meichel 00114 ** Changed include path schema for all DCMTK header files 00115 ** 00116 ** Revision 1.14 2004/07/01 12:28:25 meichel 00117 ** Introduced virtual clone method for DcmObject and derived classes. 00118 ** 00119 ** Revision 1.13 2002/12/06 12:49:16 joergr 00120 ** Enhanced "print()" function by re-working the implementation and replacing 00121 ** the boolean "showFullData" parameter by a more general integer flag. 00122 ** Added doc++ documentation. 00123 ** Made source code formatting more consistent with other modules/files. 00124 ** 00125 ** Revision 1.12 2002/04/25 09:54:28 joergr 00126 ** Removed getOFStringArray() implementation. 00127 ** 00128 ** Revision 1.11 2001/09/25 17:19:32 meichel 00129 ** Adapted dcmdata to class OFCondition 00130 ** 00131 ** Revision 1.10 2001/06/01 15:48:50 meichel 00132 ** Updated copyright header 00133 ** 00134 ** Revision 1.9 2000/03/08 16:26:24 meichel 00135 ** Updated copyright header. 00136 ** 00137 ** Revision 1.8 1999/03/31 09:25:01 meichel 00138 ** Updated copyright header in module dcmdata 00139 ** 00140 ** Revision 1.7 1998/11/12 16:47:50 meichel 00141 ** Implemented operator= for all classes derived from DcmObject. 00142 ** 00143 ** Revision 1.6 1997/09/11 15:13:14 hewett 00144 ** Modified getOFString method arguments by removing a default value 00145 ** for the pos argument. By requiring the pos argument to be provided 00146 ** ensures that callers realise getOFString only gets one component of 00147 ** a multi-valued string. 00148 ** 00149 ** Revision 1.5 1997/08/29 08:32:42 andreas 00150 ** - Added methods getOFString and getOFStringArray for all 00151 ** string VRs. These methods are able to normalise the value, i. e. 00152 ** to remove leading and trailing spaces. This will be done only if 00153 ** it is described in the standard that these spaces are not relevant. 00154 ** These methods do not test the strings for conformance, this means 00155 ** especially that they do not delete spaces where they are not allowed! 00156 ** getOFStringArray returns the string with all its parts separated by \ 00157 ** and getOFString returns only one value of the string. 00158 ** CAUTION: Currently getString returns a string with trailing 00159 ** spaces removed (if dcmEnableAutomaticInputDataCorrection == OFTrue) and 00160 ** truncates the original string (since it is not copied!). If you rely on this 00161 ** behaviour please change your application now. 00162 ** Future changes will ensure that getString returns the original 00163 ** string from the DICOM object (NULL terminated) inclusive padding. 00164 ** Currently, if you call getOF... before calling getString without 00165 ** normalisation, you can get the original string read from the DICOM object. 00166 ** 00167 ** Revision 1.4 1997/05/12 07:37:45 andreas 00168 ** - new get-Methods for DcmDecimalString: getFloat64 and 00169 ** DcmIntegerString: getSint32 00170 ** 00171 ** Revision 1.3 1996/01/05 13:23:06 andreas 00172 ** - changed to support new streaming facilities 00173 ** - more cleanups 00174 ** - merged read / write methods for block and file transfer 00175 ** 00176 */ 00177