MeVisLabToolboxReference
DCMTree::TagInfo Class Reference

Class to carry meta-information about a specific tag. More...

#include <DCMTree_TagInfo.h>

Inheritance diagram for DCMTree::TagInfo:
DCMTree_Serialization::Serializable DCMTree_Serialization::Deserializable

List of all members.

Public Member Functions

 TagInfo ()
 ctor
 TagInfo (const TagId &tagid, const Dict &dictionary)
 create a new instance, getting the values regarding the tag id from the dictionary
 TagInfo (const TagId &tagid, const Vr &vr, const TagValueMultiplicity &multiplicity)
 create a new instance, initialized with the given values
 TagInfo (const TagInfo &other)
 copy ctor
 ~TagInfo ()
 dtor
TagInfooperator= (const TagInfo &other)
 assignment operator copies all values from other to this handles self-assignment well
const TagIdid () const
 get the TagId of this
const Vrvr () const
 get the vr of this
bool isCodedString () const
 check if the string encoding depends on the specific character set
const TagValueMultiplicitymultiplicity () const
 get the multiplicity of this
void setId (const TagId &tagid)
 set the TagId of this
void setVr (const Vr &vr)
 set the vr of this
void setMultiplicity (const TagValueMultiplicity &multiplicity)
 set the multiplicity of this
void fromStream (std::istream &in, bool readName)
 extract this instance from the given stream readName = true reads tag name(s) from stream, false assumes that no name(s) is/are in stream.
void toStream (std::ostream &out, bool writeName) const
 copy this instance recursively into the given stream writeName = true writes tag name(s) to stream, false writes no name(s) into stream.
virtual void serializeX (DCMTree_Serialization::Sink &sink) const
 Writes data of this object to Sink.
virtual void deserializeX (DCMTree_Serialization::Source &source)
 Overwrites data of this object with data from Source.

Detailed Description

Class to carry meta-information about a specific tag.

Definition at line 33 of file DCMTree_TagInfo.h.


Constructor & Destructor Documentation

DCMTree::TagInfo::TagInfo ( )

ctor

DCMTree::TagInfo::TagInfo ( const TagId tagid,
const Dict dictionary 
)

create a new instance, getting the values regarding the tag id from the dictionary

DCMTree::TagInfo::TagInfo ( const TagId tagid,
const Vr vr,
const TagValueMultiplicity multiplicity 
)

create a new instance, initialized with the given values

DCMTree::TagInfo::TagInfo ( const TagInfo other)

copy ctor

DCMTree::TagInfo::~TagInfo ( )

dtor


Member Function Documentation

virtual void DCMTree::TagInfo::deserializeX ( DCMTree_Serialization::Source source) [virtual]

Overwrites data of this object with data from Source.

All the rules stated for SCR::Serializable::serializeX apply correspondingly.

See also:
SCR::Serializable::serializeX

Implements DCMTree_Serialization::Deserializable.

void DCMTree::TagInfo::fromStream ( std::istream &  in,
bool  readName 
)

extract this instance from the given stream readName = true reads tag name(s) from stream, false assumes that no name(s) is/are in stream.

IMPORTANT: This method is used for file format persistence; thus stream contents must be maintained compatible.

Referenced by DCMTree::operator>>().

const TagId& DCMTree::TagInfo::id ( ) const

get the TagId of this

bool DCMTree::TagInfo::isCodedString ( ) const

check if the string encoding depends on the specific character set

const TagValueMultiplicity& DCMTree::TagInfo::multiplicity ( ) const

get the multiplicity of this

TagInfo& DCMTree::TagInfo::operator= ( const TagInfo other)

assignment operator copies all values from other to this handles self-assignment well

virtual void DCMTree::TagInfo::serializeX ( DCMTree_Serialization::Sink sink) const [virtual]

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.

See also:
SCR

Implements DCMTree_Serialization::Serializable.

void DCMTree::TagInfo::setId ( const TagId tagid)

set the TagId of this

void DCMTree::TagInfo::setMultiplicity ( const TagValueMultiplicity multiplicity)

set the multiplicity of this

void DCMTree::TagInfo::setVr ( const Vr vr)

set the vr of this

void DCMTree::TagInfo::toStream ( std::ostream &  out,
bool  writeName 
) const

copy this instance recursively into the given stream writeName = true writes tag name(s) to stream, false writes no name(s) into stream.

IMPORTANT: This method is used for file format persistence; thus stream contents must be maintained compatible.

Referenced by DCMTree::operator<<().

const Vr& DCMTree::TagInfo::vr ( ) const

get the vr of this


The documentation for this class was generated from the following file: