DCMTK Version 3.6.8
OFFIS DICOM Toolkit
|
double-linked list class that maintains pointers to DcmObject instances. More...
Public Member Functions | |
DcmList () | |
constructor | |
~DcmList () | |
destructor | |
DcmObject * | append (DcmObject *obj) |
insert object at end of list More... | |
DcmObject * | prepend (DcmObject *obj) |
insert object at start of list More... | |
DcmObject * | insert (DcmObject *obj, E_ListPos pos=ELP_next) |
insert object relative to current position and indicator More... | |
DcmObject * | remove () |
remove current entry from list, return element More... | |
DcmObject * | get (E_ListPos pos=ELP_atpos) |
get pointer to element in list at given position More... | |
DcmObject * | seek (E_ListPos pos=ELP_next) |
seek within element in list to given position (i.e. More... | |
DcmObject * | seek_to (unsigned long absolute_position) |
seek within element in list to given element index (i.e. More... | |
void | deleteAllElements () |
Remove and delete all elements from list. More... | |
unsigned long | card () const |
return cardinality of list | |
OFBool | empty (void) const |
return true if list is empty, false otherwise | |
OFBool | valid (void) const |
return true if current node exists, false otherwise | |
Private Member Functions | |
DcmList & | operator= (const DcmList &) |
private undefined copy constructor | |
DcmList (const DcmList &newList) | |
private undefined copy assignment operator More... | |
Private Attributes | |
DcmListNode * | firstNode |
pointer to first node in list | |
DcmListNode * | lastNode |
pointer to last node in list | |
DcmListNode * | currentNode |
pointer to current node in list | |
unsigned long | cardinality |
number of elements in list | |
double-linked list class that maintains pointers to DcmObject instances.
The remove operation does not delete the object pointed to, however, the destructor will delete all elements pointed to
|
private |
private undefined copy assignment operator
newList | documented to avoid doxygen warnings |
insert object at end of list
obj | pointer to object |
void DcmList::deleteAllElements | ( | ) |
Remove and delete all elements from list.
Thus, the elements' memory is also freed by this operation. The list is empty after calling this function.
DcmObject * DcmList::get | ( | E_ListPos | pos = ELP_atpos | ) |
get pointer to element in list at given position
pos | position indicator |
insert object relative to current position and indicator
obj | pointer to object |
pos | position indicator |
insert object at start of list
obj | pointer to object |
DcmObject * DcmList::remove | ( | ) |
remove current entry from list, return element
DcmObject * DcmList::seek | ( | E_ListPos | pos = ELP_next | ) |
seek within element in list to given position (i.e.
set current element to given position)
pos | position indicator |
DcmObject * DcmList::seek_to | ( | unsigned long | absolute_position | ) |
seek within element in list to given element index (i.e.
set current element to given index)
absolute_position | position index < card() |