GDCM
2.2.0
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
Source
DataStructureAndEncodingDefinition
gdcmPDBElement.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: GDCM (Grassroots DICOM). A DICOM library
4
5
Copyright (c) 2006-2011 Mathieu Malaterre
6
All rights reserved.
7
See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8
9
This software is distributed WITHOUT ANY WARRANTY; without even
10
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11
PURPOSE. See the above copyright notice for more information.
12
13
=========================================================================*/
14
#ifndef GDCMPDBELEMENT_H
15
#define GDCMPDBELEMENT_H
16
17
#include "
gdcmTag.h
"
18
#include "
gdcmVM.h
"
19
#include "
gdcmVR.h
"
20
#include "
gdcmByteValue.h
"
21
#include "
gdcmSmartPointer.h
"
22
23
namespace
gdcm
24
{
29
class
GDCM_EXPORT
PDBElement
30
{
31
public
:
32
PDBElement
() {}
33
34
friend
std::ostream&
operator<<
(std::ostream &os,
const
PDBElement
&val);
35
37
const
char
*
GetName
()
const
{
return
NameField.c_str(); }
38
void
SetName
(
const
char
*name) { NameField = name; }
39
41
const
char
*
GetValue
()
const
{
return
ValueField.c_str(); }
42
void
SetValue
(
const
char
*value) { ValueField = value; }
43
44
bool
operator==
(
const
PDBElement
&de)
const
45
{
46
return
ValueField == de.
ValueField
47
&& NameField == de.
NameField
;
48
}
49
50
protected
:
51
std::string
NameField
;
52
std::string
ValueField
;
53
};
54
//-----------------------------------------------------------------------------
55
inline
std::ostream&
operator<<
(std::ostream &os,
const
PDBElement
&val)
56
{
57
os << val.
NameField
;
58
os <<
" \""
;
59
os << val.
ValueField
;
60
os <<
"\""
;
61
62
return
os;
63
}
64
65
}
// end namespace gdcm
66
67
#endif //GDCMPDBELEMENT_H
Generated on Wed Jun 13 2012 20:40:37 for GDCM by
1.8.1