odil
Main Page
Classes
Files
File List
src
odil
ElementsDictionary.h
1
/*************************************************************************
2
* odil - Copyright (C) Universite de Strasbourg
3
* Distributed under the terms of the CeCILL-B license, as published by
4
* the CEA-CNRS-INRIA. Refer to the LICENSE file or to
5
* http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
6
* for details.
7
************************************************************************/
8
9
#ifndef _f4b88e07_d515_41be_ad1b_37899ec6451e
10
#define _f4b88e07_d515_41be_ad1b_37899ec6451e
11
12
#include <map>
13
#include <string>
14
15
#include <odil/Tag.h>
16
17
namespace
odil
18
{
19
21
class
ElementsDictionaryKey
22
{
23
public
:
25
enum class
Type
26
{
27
Tag
,
28
String,
29
None
30
};
31
33
ElementsDictionaryKey
();
34
36
ElementsDictionaryKey
(
Tag
const
& value);
37
39
ElementsDictionaryKey
(std::string
const
& value);
40
42
Type
const
&
get_type
()
const
;
43
45
Tag
const
&
get_tag
()
const
;
46
48
std::string
const
&
get_string
()
const
;
49
51
void
set
(
Tag
const
value);
52
54
void
set
(std::string
const
& value);
55
57
bool
operator<
(
ElementsDictionaryKey
const
& other)
const
;
58
60
bool
operator==
(
ElementsDictionaryKey
const
& other)
const
;
61
62
private
:
63
Type
_type;
64
Tag
_tag;
65
std::string _string;
66
};
67
71
struct
ElementsDictionaryEntry
72
{
73
std::string name;
74
std::string keyword;
75
std::string vr;
76
std::string vm;
77
78
ElementsDictionaryEntry
(
79
std::string
const
& name=
""
, std::string
const
& keyword=
""
,
80
std::string
const
& vr=
""
, std::string
const
& vm=
""
);
81
};
82
83
typedef
84
std::map<ElementsDictionaryKey, ElementsDictionaryEntry> ElementsDictionary;
85
86
}
87
88
#endif // _f4b88e07_d515_41be_ad1b_37899ec6451e
odil::ElementsDictionaryKey::get_tag
Tag const & get_tag() const
Return the tag value or raise an exception if type is not Tag.
Definition:
ElementsDictionary.cpp:46
odil
Definition:
Association.cpp:39
odil::Tag
A DICOM element tag.
Definition:
Tag.h:22
odil::ElementsDictionaryKey::get_type
Type const & get_type() const
Return the type.
Definition:
ElementsDictionary.cpp:39
odil::ElementsDictionaryKey::ElementsDictionaryKey
ElementsDictionaryKey()
Create a key with type equal to None.
Definition:
ElementsDictionary.cpp:19
odil::ElementsDictionaryKey::Type
Type
Type of the key.
Definition:
ElementsDictionary.h:25
odil::ElementsDictionaryKey::operator==
bool operator==(ElementsDictionaryKey const &other) const
Comparator.
Definition:
ElementsDictionary.cpp:108
odil::ElementsDictionaryKey::get_string
std::string const & get_string() const
Return the string value or raise an exception if type is not String.
Definition:
ElementsDictionary.cpp:57
odil::ElementsDictionaryKey::operator<
bool operator<(ElementsDictionaryKey const &other) const
Comparator.
Definition:
ElementsDictionary.cpp:84
odil::ElementsDictionaryKey
Key of a dictionary of DICOM elements.
Definition:
ElementsDictionary.h:21
odil::ElementsDictionaryEntry
Entry in a dictionary of DICOM elements.
Definition:
ElementsDictionary.h:71
Generated by
1.8.11