OFFIS DCMTK  Version 3.6.0
Public Member Functions | Protected Member Functions | Private Attributes | Friends | List of all members
DSRTemporalCoordinatesValue Class Reference

Class for spatial coordinate values. More...

Inheritance diagram for DSRTemporalCoordinatesValue:
[legend]
Collaboration diagram for DSRTemporalCoordinatesValue:
[legend]

Public Member Functions

 DSRTemporalCoordinatesValue ()
 default contructor
 
 DSRTemporalCoordinatesValue (const DSRTypes::E_TemporalRangeType temporalRangeType)
 constructor
 
 DSRTemporalCoordinatesValue (const DSRTemporalCoordinatesValue &coordinatesValue)
 copy constructor
 
virtual ~DSRTemporalCoordinatesValue ()
 destructor
 
DSRTemporalCoordinatesValueoperator= (const DSRTemporalCoordinatesValue &coordinatesValue)
 assignment operator
 
virtual void clear ()
 clear all internal variables.
 
virtual OFBool isValid () const
 check whether the current spatial coordinates value is valid.
 
virtual OFBool isShort (const size_t flags) const
 check whether the content is short.
 
virtual OFCondition print (STD_NAMESPACE ostream &stream, const size_t flags) const
 print temporal coordinates.
 
virtual OFCondition readXML (const DSRXMLDocument &doc, DSRXMLCursor cursor)
 read temporal coordinates value from XML document
 
virtual OFCondition writeXML (STD_NAMESPACE ostream &stream, const size_t flags) const
 write temporal coordinates value in XML format
 
virtual OFCondition renderHTML (STD_NAMESPACE ostream &docStream, STD_NAMESPACE ostream &annexStream, size_t &annexNumber, const size_t flags) const
 render temporal coordinates value in HTML/XHTML format
 
const DSRTemporalCoordinatesValuegetValue () const
 get reference to temporal coordinates value
 
OFCondition getValue (DSRTemporalCoordinatesValue &coordinatesValue) const
 get copy of temporal coordinates value
 
OFCondition setValue (const DSRTemporalCoordinatesValue &coordinatesValue)
 set temporal coordinates value.
 
DSRTypes::E_TemporalRangeType getTemporalRangeType () const
 get current temporal range type.
 
OFCondition setTemporalRangeType (const DSRTypes::E_TemporalRangeType temporalRangeType)
 set current temporal range type.
 
DSRReferencedDatetimeListgetDatetimeList ()
 get reference to list of referenced datetime
 
DSRReferencedSamplePositionListgetSamplePositionList ()
 get reference to list of referenced sample positions
 
DSRReferencedTimeOffsetListgetTimeOffsetList ()
 get reference to list of referenced time offsets
 

Protected Member Functions

DSRTemporalCoordinatesValuegetValuePtr ()
 get pointer to temporal coordinates value
 
virtual OFCondition read (DcmItem &dataset)
 read temporal coordinates value from dataset.
 
virtual OFCondition write (DcmItem &dataset) const
 write temporal coordinates reference value to dataset.
 
OFBool checkData (const DSRTypes::E_TemporalRangeType temporalRangeType, const DSRReferencedSamplePositionList &samplePositionList, const DSRReferencedTimeOffsetList &timeOffsetList, const DSRReferencedDatetimeList &datetimeList) const
 check the temporal range type and other data for validity.
 

Private Attributes

DSRTypes::E_TemporalRangeType TemporalRangeType
 temporal range type (associated DICOM VR=CS, type 1)
 
DSRReferencedSamplePositionList SamplePositionList
 list of referenced sample positions (associated DICOM VR=UL, VM=1-n, type 1C)
 
DSRReferencedTimeOffsetList TimeOffsetList
 list of referenced time offsets (associated DICOM VR=DS, VM=1-n, type 1C)
 
DSRReferencedDatetimeList DatetimeList
 list of referenced datetime (associated DICOM VR=DT, VM=1-n, type 1C)
 

Friends

class DSRContentItem
 

Detailed Description

Class for spatial coordinate values.

Definition at line 48 of file dsrtcovl.h.

Constructor & Destructor Documentation

DSRTemporalCoordinatesValue::DSRTemporalCoordinatesValue ( const DSRTypes::E_TemporalRangeType  temporalRangeType)

constructor

Parameters
temporalRangeTypetype of temporal extent of the region of interest
DSRTemporalCoordinatesValue::DSRTemporalCoordinatesValue ( const DSRTemporalCoordinatesValue coordinatesValue)

copy constructor

Parameters
coordinatesValuetemporal coordinates value to be copied (not checked !)

Member Function Documentation

OFBool DSRTemporalCoordinatesValue::checkData ( const DSRTypes::E_TemporalRangeType  temporalRangeType,
const DSRReferencedSamplePositionList samplePositionList,
const DSRReferencedTimeOffsetList timeOffsetList,
const DSRReferencedDatetimeList datetimeList 
) const
protected

check the temporal range type and other data for validity.

The data is valid if the 'temporalRangeType' is valid and at least one of the three lists are non-empty. If more the one list is non-empty a warning is reported since they are mutually exclusive (type 1C).

Parameters
temporalRangeTypetemporal range type to be checked
samplePositionListlist of referenced sample positions to be checked
timeOffsetListlist of referenced time offsets to be checked
datetimeListlist of referenced datetime to be checked
Returns
OFTrue if data is valid, OFFalse otherwise
virtual void DSRTemporalCoordinatesValue::clear ( )
virtual

clear all internal variables.

Temporal range type is set to TRT_invalid. Since an empty list of graphic data is invalid the spatial coordinates value becomes invalid afterwards.

Reimplemented in DSRTCoordTreeNode.

DSRReferencedDatetimeList& DSRTemporalCoordinatesValue::getDatetimeList ( )
inline

get reference to list of referenced datetime

Returns
reference to list

Definition at line 182 of file dsrtcovl.h.

References DatetimeList.

DSRReferencedSamplePositionList& DSRTemporalCoordinatesValue::getSamplePositionList ( )
inline

get reference to list of referenced sample positions

Returns
reference to list

Definition at line 190 of file dsrtcovl.h.

References SamplePositionList.

DSRTypes::E_TemporalRangeType DSRTemporalCoordinatesValue::getTemporalRangeType ( ) const
inline

get current temporal range type.

This value represents the type of temporal extent of the region of interest.

Returns
region type (might be TRT_invalid)

Definition at line 167 of file dsrtcovl.h.

References TemporalRangeType.

DSRReferencedTimeOffsetList& DSRTemporalCoordinatesValue::getTimeOffsetList ( )
inline

get reference to list of referenced time offsets

Returns
reference to list

Definition at line 198 of file dsrtcovl.h.

References TimeOffsetList.

const DSRTemporalCoordinatesValue& DSRTemporalCoordinatesValue::getValue ( ) const
inline

get reference to temporal coordinates value

Returns
reference to temporal coordinates value

Definition at line 143 of file dsrtcovl.h.

OFCondition DSRTemporalCoordinatesValue::getValue ( DSRTemporalCoordinatesValue coordinatesValue) const

get copy of temporal coordinates value

Parameters
coordinatesValuereference to variable in which the value should be stored
Returns
status, EC_Normal if successful, an error code otherwise
DSRTemporalCoordinatesValue* DSRTemporalCoordinatesValue::getValuePtr ( )
inlineprotected

get pointer to temporal coordinates value

Returns
pointer to temporal coordinates value (never NULL)

Definition at line 209 of file dsrtcovl.h.

virtual OFBool DSRTemporalCoordinatesValue::isShort ( const size_t  flags) const
virtual

check whether the content is short.

This method is used to check whether the rendered output of this content item can be expanded inline or not (used for renderHTML()).

Parameters
flagsflag used to customize the output (see DSRTypes::HF_xxx)
Returns
OFTrue if the content is short, OFFalse otherwise

Reimplemented in DSRTCoordTreeNode.

virtual OFBool DSRTemporalCoordinatesValue::isValid ( ) const
virtual

check whether the current spatial coordinates value is valid.

The value is valid if the temporal range type is not TRT_invalid and the other data is valid (see checkData() for details).

Returns
OFTrue if reference value is valid, OFFalse otherwise

Reimplemented in DSRTCoordTreeNode.

DSRTemporalCoordinatesValue& DSRTemporalCoordinatesValue::operator= ( const DSRTemporalCoordinatesValue coordinatesValue)

assignment operator

Parameters
coordinatesValueTemporal coordinates value to be copied (not checked !)
Returns
reference to this Temporal coordinates value after 'coordinatesValue' has been copied
virtual OFCondition DSRTemporalCoordinatesValue::print ( STD_NAMESPACE ostream &  stream,
const size_t  flags 
) const
virtual

print temporal coordinates.

The output of a typical temporal coordinates value looks like this (depending on the referenced data list): (SEGMENT,1,2,3) or (SEGMENT,1,2.5,3.1) or (POINT,20001010120000)

Parameters
streamoutput stream to which the temporal coordinates value should be printed
flagsflag used to customize the output (see DSRTypes::PF_xxx)
Returns
status, EC_Normal if successful, an error code otherwise

Reimplemented in DSRTCoordTreeNode.

virtual OFCondition DSRTemporalCoordinatesValue::read ( DcmItem dataset)
protectedvirtual

read temporal coordinates value from dataset.

Please note that all three lists are (tried to) read from the dataset. If more than one list is present a warning messsage is reported.

Parameters
datasetDICOM dataset from which the value should be read
Returns
status, EC_Normal if successful, an error code otherwise
virtual OFCondition DSRTemporalCoordinatesValue::readXML ( const DSRXMLDocument doc,
DSRXMLCursor  cursor 
)
virtual

read temporal coordinates value from XML document

Parameters
docdocument containing the XML file content
cursorcursor pointing to the starting node
Returns
status, EC_Normal if successful, an error code otherwise
virtual OFCondition DSRTemporalCoordinatesValue::renderHTML ( STD_NAMESPACE ostream &  docStream,
STD_NAMESPACE ostream &  annexStream,
size_t &  annexNumber,
const size_t  flags 
) const
virtual

render temporal coordinates value in HTML/XHTML format

Parameters
docStreamoutput stream to which the main HTML/XHTML document is written
annexStreamoutput stream to which the HTML/XHTML document annex is written
annexNumberreference to the variable where the current annex number is stored. Value is increased automatically by 1 after a new entry has been added.
flagsflag used to customize the output (see DSRTypes::HF_xxx)
Returns
status, EC_Normal if successful, an error code otherwise
OFCondition DSRTemporalCoordinatesValue::setTemporalRangeType ( const DSRTypes::E_TemporalRangeType  temporalRangeType)

set current temporal range type.

This value represents the type of temporal extent of the region of interest.

Parameters
temporalRangeTypetemporal range type to be set (TRT_invalid is not allowed)
Returns
status, EC_Normal if successful, an error code otherwise
OFCondition DSRTemporalCoordinatesValue::setValue ( const DSRTemporalCoordinatesValue coordinatesValue)

set temporal coordinates value.

Before setting the value the temporal range type and other data are checked (see checkData()). If the value is invalid the current value is not replaced and remains unchanged.

Parameters
coordinatesValuevalue to be set
Returns
status, EC_Normal if successful, an error code otherwise
virtual OFCondition DSRTemporalCoordinatesValue::write ( DcmItem dataset) const
protectedvirtual

write temporal coordinates reference value to dataset.

Please note that only one of the three lists is actually written to the dataset.

Parameters
datasetDICOM dataset to which the value should be written
Returns
status, EC_Normal if successful, an error code otherwise
virtual OFCondition DSRTemporalCoordinatesValue::writeXML ( STD_NAMESPACE ostream &  stream,
const size_t  flags 
) const
virtual

write temporal coordinates value in XML format

Parameters
streamoutput stream to which the XML document is written
flagsflag used to customize the output (see DSRTypes::XF_xxx)
Returns
status, EC_Normal if successful, an error code otherwise

Reimplemented in DSRTCoordTreeNode.


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


Generated on Thu Dec 20 2012 for OFFIS DCMTK Version 3.6.0 by Doxygen 1.8.2