33 #include "dcmtk/config/osconfig.h" 35 #include "dcmtk/dcmdata/dctypes.h" 36 #include "dcmtk/dcmdata/dcelem.h" 37 #include "dcmtk/ofstd/ofstring.h" 65 const Uint32 len = 0);
107 virtual DcmEVR
ident()
const;
117 virtual unsigned long getVM();
132 virtual Uint32
getLength(
const E_TransferSyntax xfer = EXS_LittleEndianImplicit,
133 const E_EncodingType enctype = EET_UndefinedLength);
144 virtual void print(STD_NAMESPACE ostream&out,
145 const size_t flags = 0,
147 const char *pixelFileName = NULL,
148 size_t *pixelCounter = NULL);
157 const E_TransferSyntax oxfer,
158 const E_EncodingType enctype,
169 const E_TransferSyntax oxfer,
170 const E_EncodingType enctype,
180 const unsigned long pos,
181 OFBool normalize = OFTrue);
227 virtual OFBool
isEmpty(
const OFBool normalize = OFTrue);
295 const size_t maxLen = 0);
322 const OFBool DELETE_TRAILING = OFTrue;
324 const OFBool DELETE_LEADING = OFTrue;
326 const OFBool MULTIPART = OFTrue;
342 const unsigned long pos);
351 void normalizeString(
OFString &
string,
352 const OFBool multiPart,
353 const OFBool leading,
354 const OFBool trailing);
DcmByteString & operator=(const DcmByteString &obj)
assignment operator
void setPaddingChar(char c)
set the end-of-string padding character
virtual OFCondition getOFString(OFString &stringVal, const unsigned long pos, OFBool normalize=OFTrue)
get a copy of a particular string component
virtual Uint32 getLength(const E_TransferSyntax xfer=EXS_LittleEndianImplicit, const E_EncodingType enctype=EET_UndefinedLength)
get DICOM length of the stored value.
abstract base class for all DICOM elements
DcmByteString(const DcmTag &tag, const Uint32 len=0)
constructor.
virtual OFCondition clear()
clear the currently stored value
void setMaxLength(Uint32 val)
set the maximum number of characters for each string component
virtual OFBool isAffectedBySpecificCharacterSet() const
check if this element is affected by SpecificCharacterSet
virtual unsigned long getVM()
get value multiplicity
static OFCondition checkStringValue(const OFString &value, const OFString &vm, const OFString &vr, const int vrID, const size_t maxLen=0)
check whether given string value conforms to a certain VR and VM.
this class encapsulates an attribute tag (group, element) and a VR.
virtual ~DcmByteString()
destructor
This class implements a buffering mechanism that is used when writing large elements that reside in f...
base class for output streams.
E_StringMode fStringMode
current representation of the string value
virtual void print(STD_NAMESPACE ostream &out, const size_t flags=0, const int level=0, const char *pixelFileName=NULL, size_t *pixelCounter=NULL)
print element to a stream.
Abstract base class for most classes in module dcmdata.
Uint32 maxLength
maximum number of characters for each string component
virtual OFCondition writeSignatureFormat(DcmOutputStream &outStream, const E_TransferSyntax oxfer, const E_EncodingType enctype, DcmWriteCache *wcache)
write data element to a stream as required for the creation of digital signatures ...
char paddingChar
padding character used to adjust odd value length (space)
Uint32 realLength
number of characters of the internal string representation
string has unknown representation (maybe multiple padding chars?)
virtual OFCondition putString(const char *stringVal)
set element value from the given character string
virtual DcmObject * clone() const
clone method
virtual OFBool isEmpty(const OFBool normalize=OFTrue)
check if this object is empty
base class for all DICOM value representations storing a character string
virtual DcmEVR ident() const
get element type identifier
string has internal representation (no padding)
virtual OFCondition write(DcmOutputStream &outStream, const E_TransferSyntax oxfer, const E_EncodingType enctype, DcmWriteCache *wcache)
write data element to a stream
virtual OFCondition verify(const OFBool autocorrect=OFFalse)
check the currently stored string value.
virtual Uint8 * newValueField()
create a new value field (string buffer) of the previously defined size (member variable 'Length')...
virtual OFCondition makeMachineByteString()
convert currently stored string value to internal representation.
OFCondition makeDicomByteString()
convert currently stored string value to DICOM representation.
string has DICOM representation (even length)
Uint32 getRealLength()
get length of the stored value.
OFString nonSignificantChars
non significant characters used to determine whether the value is empty
a simple string class that implements a subset of std::string.
virtual OFCondition getString(char *&stringVal)
get a pointer to the current string value.
virtual OFCondition putOFStringArray(const OFString &stringVal)
set element value from the given character string.
void setNonSignificantChars(const OFString &characters)
set non-significant characters used to determine whether the value is empty
virtual OFCondition copyFrom(const DcmObject &rhs)
Virtual object copying.
virtual void postLoadValue()
method is called after the element value has been loaded.
virtual OFBool containsExtendedCharacters(const OFBool checkAllStrings=OFFalse)
check if this element contains non-ASCII characters
E_StringMode
internal type used to specify the current string representation
General purpose class for condition codes.
OFCondition getStringValue(OFString &stringVal)
get a copy of the current string value.