CodeString This is an implementation of DICOM VR: CS The cstor will properly Trim so that operator== is correct.
More...
#include <gdcmCodeString.h>
List of all members.
Detailed Description
CodeString This is an implementation of DICOM VR: CS The cstor will properly Trim so that operator== is correct.
- Note:
- the cstor of CodeString will Trim the string on the fly so as to remove the extra leading and ending spaces. However it will not perform validation on the fly (CodeString obj can contains invalid char such as lower cases). This design was chosen to be a little tolerant to broken DICOM implementation, and thus allow user to compare lower case CS from there input file without the need to first rewrite them to get rid of invalid character (validation is a different operation from searching, querying).
- Warning:
- when writing out DICOM file it is highly recommended to perform the IsValid() call, at least to check that the length of the string match the definition in the standard.
Member Typedef Documentation
Constructor & Destructor Documentation
gdcm::CodeString::CodeString |
( |
) |
[inline] |
gdcm::CodeString::CodeString |
( |
const value_type * |
s ) |
[inline] |
Member Function Documentation
std::string gdcm::CodeString::GetAsString |
( |
) |
const [inline] |
Return the full code string as std::string.
bool gdcm::CodeString::IsValid |
( |
) |
const |
size_type gdcm::CodeString::Size |
( |
) |
const [inline] |
Return the size of the string.
std::string gdcm::CodeString::Trim |
( |
) |
const |
std::string gdcm::CodeString::TrimInternal |
( |
) |
const [inline, protected] |
Friends And Related Function Documentation
std::ostream& operator<< |
( |
std::ostream & |
os, |
|
|
const CodeString & |
str |
|
) |
| [friend] |
The documentation for this class was generated from the following file: