vtk-dicom
0.8.17
|
A sequence of items according to the SQ representation. More...
#include <vtkDICOMSequence.h>
Public Member Functions | |
vtkDICOMSequence () | |
Construct a growable sequence with no items. | |
vtkDICOMSequence (unsigned int n) | |
Construct a sequence of fixed size. | |
void | Clear () |
Clear a sequence, remove its contents and make it empty. | |
const vtkDICOMValue & | Get (size_t i, vtkDICOMTag tag) const |
Get a value from an item in the sequence. | |
const vtkDICOMValue & | Get (size_t i, const vtkDICOMTagPath &p) const |
const vtkDICOMValue & | GetAttributeValue (size_t i, vtkDICOMTag tag) const |
const vtkDICOMValue & | GetAttributeValue (size_t i, const vtkDICOMTagPath &p) const |
void | AddItem (const vtkDICOMItem &item) |
Add an item to the sequence. More... | |
size_t | GetNumberOfItems () const |
Get the number of items in the sequence. | |
void | SetItem (size_t i, const vtkDICOMItem &item) |
Set an item in the sequence. More... | |
const vtkDICOMItem & | GetItem (size_t i) const |
Get an item from the sequence. | |
const vtkDICOMItem * | GetSequenceData () const |
Get a pointer to the items in the sequence. | |
vtkDICOMSequence (const vtkDICOMSequence &o) | |
Copy constructor. | |
vtkDICOMSequence (const vtkDICOMValue &o) | |
Conversion from value to sequence is type checked. | |
bool | IsValid () const |
Check that the sequence was constructed from a valid value. | |
vtkDICOMSequence & | operator= (const vtkDICOMSequence &o) |
Assignment operator. | |
vtkDICOMSequence & | operator= (const vtkDICOMValue &o) |
Assignment from value to sequence is type checked. | |
Friends | |
class | vtkDICOMValue |
A sequence of items according to the SQ representation.
This class is for constructing and decoding sequences. There are two ways that sequences can be constructed: A fixed-size sequence can be created and then its items filled in with the SetItem() method, or, you can start with an empty sequence and use AddItem() to append items.
void vtkDICOMSequence::AddItem | ( | const vtkDICOMItem & | item | ) |
Add an item to the sequence.
After calling this method, GetNumberOfItems() will report the number of items in the sequence, but GetVL() will return the special value 0xffffffff to indicate that this is a delimited sequence rather than a fixed-size sequence.
void vtkDICOMSequence::SetItem | ( | size_t | i, |
const vtkDICOMItem & | item | ||
) |
Set an item in the sequence.
This method can only be used if space as been allocated within the sequence by specifying a size when calling the constructor.