MeVisLab Toolbox Reference
|
Class to wrap a tag-id. More...
#include <DCMTree_TagId.h>
Public Member Functions | |
TagId () | |
ctor - sets the id to (0000,0000) More... | |
TagId (RawTagId rawid) | |
ctor - initialize to the given value More... | |
TagId (const TagId &other) | |
copy ctor More... | |
TagId (unsigned short groupid, unsigned short elementid) | |
ctor - create a new instance with id (groupid,elementid) More... | |
TagId (std::string tidstr) | |
ctor - create a new instance by conversion from the given string accepts string of the form t*H*t*,t*H*t* t* : any number of non , and non digits (a-f,A-F,0-9) H* : any number of digits (a-f,A-F,0-9) More... | |
~TagId () override | |
dtor More... | |
TagId & | operator= (const TagId &other) |
assignment operator (used by copy-ctor) More... | |
bool | operator== (const TagId &other) const |
is-equal operator More... | |
bool | operator!= (const TagId &other) const |
is-not-equal operator More... | |
bool | operator> (const TagId &other) const |
is-bigger-than operator More... | |
bool | operator< (const TagId &other) const |
is-less-than operator More... | |
bool | operator>= (const TagId &other) const |
if-bigger-than-or-equal operator More... | |
bool | operator<= (const TagId &other) const |
if-smaller-than-or-equal operator More... | |
operator RawTagId () const | |
get access to the raw-id using auto-conversion More... | |
operator RawTagId & () | |
get access to the raw-id using auto-conversion More... | |
unsigned short | groupId () const |
get the upper word of the id -> group-identifier More... | |
unsigned short | elementId () const |
get the lower word of the id -> element-identifier More... | |
bool | isPrivate () const |
check if this id identifies a private tag (groupid is odd) More... | |
bool | isPrivateCreator () const |
check if this id identifies a private creator tag More... | |
RawTagId | privateTag (unsigned short slot) const |
Returns the tag ID of the corresponding private tag with the given slot. More... | |
RawTagId | rawId () const |
access the raw value More... | |
RawTagId & | rawId () |
access the raw value More... | |
std::string | toString () const |
convert this to a string of the form (groupid,elementid) More... | |
void | fromStream (std::istream &in) |
extract this instance from the given stream More... | |
void | toStream (std::ostream &out) const |
copy this instance recursively into the given stream More... | |
void | serializeX (DCMTree_Serialization::Sink &sink) const override |
Writes data of this object to Sink. More... | |
void | deserializeX (DCMTree_Serialization::Source &source) override |
Overwrites data of this object with data from Source. More... | |
Public Member Functions inherited from DCMTree_Serialization::Serializable | |
virtual | ~Serializable () |
Empty. More... | |
Public Member Functions inherited from DCMTree_Serialization::Deserializable | |
virtual | ~Deserializable () |
Empty. More... | |
Static Public Member Functions | |
static TagIdPtr | create (RawTagId rawid) |
static TagIdPtr | create (const TagId &other) |
static TagIdPtr | create (unsigned short groupid, unsigned short elementid) |
static TagIdPtr | create (std::string tidstr) |
static bool | isPrivateTag (RawTagId id) |
Returns true if the given tag ID belongs to a private tag. More... | |
Class to wrap a tag-id.
Definition at line 39 of file DCMTree_TagId.h.
DCMTree::TagId::TagId | ( | ) |
ctor - sets the id to (0000,0000)
DCMTree::TagId::TagId | ( | RawTagId | rawid | ) |
ctor - initialize to the given value
DCMTree::TagId::TagId | ( | const TagId & | other | ) |
copy ctor
DCMTree::TagId::TagId | ( | unsigned short | groupid, |
unsigned short | elementid | ||
) |
ctor - create a new instance with id (groupid,elementid)
DCMTree::TagId::TagId | ( | std::string | tidstr | ) |
ctor - create a new instance by conversion from the given string accepts string of the form t*H*t*,t*H*t* t* : any number of non , and non digits (a-f,A-F,0-9) H* : any number of digits (a-f,A-F,0-9)
|
override |
dtor
|
static |
|
static |
|
overridevirtual |
Overwrites data of this object with data from Source.
All the rules stated for SCR::Serializable::serializeX apply correspondingly.
Implements DCMTree_Serialization::Deserializable.
unsigned short DCMTree::TagId::elementId | ( | ) | const |
get the lower word of the id -> element-identifier
void DCMTree::TagId::fromStream | ( | std::istream & | in | ) |
extract this instance from the given stream
Referenced by DCMTree::operator>>().
unsigned short DCMTree::TagId::groupId | ( | ) | const |
get the upper word of the id -> group-identifier
bool DCMTree::TagId::isPrivate | ( | ) | const |
check if this id identifies a private tag (groupid is odd)
bool DCMTree::TagId::isPrivateCreator | ( | ) | const |
check if this id identifies a private creator tag
|
inlinestatic |
Returns true if the given tag ID belongs to a private tag.
Definition at line 147 of file DCMTree_TagId.h.
DCMTree::TagId::operator RawTagId | ( | ) | const |
get access to the raw-id using auto-conversion
DCMTree::TagId::operator RawTagId & | ( | ) |
get access to the raw-id using auto-conversion
bool DCMTree::TagId::operator!= | ( | const TagId & | other | ) | const |
is-not-equal operator
bool DCMTree::TagId::operator< | ( | const TagId & | other | ) | const |
is-less-than operator
bool DCMTree::TagId::operator<= | ( | const TagId & | other | ) | const |
if-smaller-than-or-equal operator
bool DCMTree::TagId::operator== | ( | const TagId & | other | ) | const |
is-equal operator
bool DCMTree::TagId::operator> | ( | const TagId & | other | ) | const |
is-bigger-than operator
bool DCMTree::TagId::operator>= | ( | const TagId & | other | ) | const |
if-bigger-than-or-equal operator
RawTagId DCMTree::TagId::privateTag | ( | unsigned short | slot | ) | const |
Returns the tag ID of the corresponding private tag with the given slot.
slot | The slot of the private tag, e.g. the element ID of the corresponding private creator tag. |
RawTagId& DCMTree::TagId::rawId | ( | ) |
access the raw value
RawTagId DCMTree::TagId::rawId | ( | ) | const |
access the raw value
|
overridevirtual |
Writes data of this object to Sink.
Implementations of Serializable::serializeX should strictly follow this pattern:
class C: public SCR::Serializable { T1 _m1; T2 _m2; T3 _m3; public: void serializeX(SCR::Sink &sink) const { SCR::serializeX(sink, _m1); SCR::serializeX(sink, _m2); SCR::serializeX(sink, _m3); } };
That is you should call some overloading of SCR::serializeX for every member.
If some of the types T1, T2, T3 are not serializable, you should make them serializable.
Implements DCMTree_Serialization::Serializable.
void DCMTree::TagId::toStream | ( | std::ostream & | out | ) | const |
copy this instance recursively into the given stream
Referenced by DCMTree::operator<<().
std::string DCMTree::TagId::toString | ( | ) | const |
convert this to a string of the form (groupid,elementid)