| 
    MeVisLab Toolbox Reference
    
   | 
 
Container with the ability to detect double inserts. More...
#include <WEMContainer.h>
  
Public Member Functions | |
| WEMContainer (unsigned int init=0) | |
| Standard constructor.   | |
| WEMContainer (WEMContainer &&) noexcept=default | |
| WEMContainer & | operator= (WEMContainer &&) noexcept=default | 
| ~WEMContainer () override | |
| Standard destructor.   | |
| T * | at (unsigned int pos) | 
| Returns the element at the given position, typecast from WEMPrimitive to T.   | |
| const T * | at (unsigned int pos) const | 
| Returns the element at the given position, typecast from WEMPrimitive to T.   | |
| void | swap (unsigned int i, unsigned int j) override | 
| Swaps elements and updates their indices.   | |
| unsigned int | append (WEMPrimitive *wp) override | 
| Appends the given element to this vector and updates the index.   | |
| int | remove (WEMPrimitive *wp) override | 
| Removes the given element from vector.   | |
| void | replace (WEMPrimitive *wp, unsigned int pos) override | 
| Replaces the given element at the given position, updates index.   | |
| void | destroy () override | 
| Destroys all elements in this vector.   | |
  Public Member Functions inherited from ml::WEMVector< WEMPrimitive > | |
| WEMVector (unsigned int init=0) | |
| Standard constructor.   | |
| WEMVector (WEMVector &&other) noexcept | |
| WEMVector & | operator= (WEMVector &&other) noexcept | 
| virtual | ~WEMVector () | 
| Standard destructor.   | |
| unsigned int | num () const | 
| Returns the number of elements in this vector.   | |
| WEMPrimitive * | at (unsigned int pos) const | 
| Returns the element at the given position or returns NULL if out of range.   | |
| WEMPrimitive * | first () | 
| Returns the first element.   | |
| const WEMPrimitive * | first () const | 
| Returns the first element.   | |
| WEMPrimitive * | last () | 
| Returns the last element.   | |
| const WEMPrimitive * | last () const | 
| Returns the last element.   | |
| virtual unsigned int | append (WEMPrimitive *elem) | 
| Appends the given element to back of this vector.   | |
| virtual void | clear () | 
| Clears all internal pointers.   | |
| virtual void | deleteAt (unsigned int pos) | 
| Deletes the element at the given position.   | |
| virtual void | deleteLast () | 
| Deletes the last element of this vector.   | |
| virtual int | remove (WEMPrimitive *elem) | 
| Deletes the element given by its pointer.   | |
| virtual int | lookup (WEMPrimitive *elem) const | 
| Searches for the given element in this vector and returns its position.   | |
| virtual int | removeUnSwapped (WEMPrimitive *elem) | 
| Deletes the element given by its pointer. Keeps the order of the elements!   | |
| virtual void | replace (WEMPrimitive *elem, unsigned int pos) | 
| Replaces the given position with the given element.   | |
| void | reserve (unsigned int init) | 
Reserves init elements, copies old ones if existing.   | |
Additional Inherited Members | |
  Protected Member Functions inherited from ml::WEMVector< WEMPrimitive > | |
| virtual void | expand () | 
| Grow vector, add extra block of size BLOCKSIZE.   | |
| virtual unsigned int | appendUnsafe (WEMPrimitive *elem) | 
| Append element to back of vector, don't check on element being non-NULL.   | |
Container with the ability to detect double inserts.
Uses _heapPosition to prevent conflicts with _entryNumber.
Definition at line 26 of file WEMContainer.h.
Standard constructor.
Definition at line 57 of file WEMContainer.h.
      
  | 
  defaultnoexcept | 
      
  | 
  override | 
Standard destructor.
Definition at line 65 of file WEMContainer.h.
      
  | 
  override | 
Appends the given element to this vector and updates the index.
Only works if element is not yet in vector!
Definition at line 131 of file WEMContainer.h.
References mlrange_cast().
Returns the element at the given position, typecast from WEMPrimitive to T.
Definition at line 72 of file WEMContainer.h.
References mlrange_cast(), and T.
Returns the element at the given position, typecast from WEMPrimitive to T.
Definition at line 88 of file WEMContainer.h.
      
  | 
  overridevirtual | 
Destroys all elements in this vector.
Reimplemented from ml::WEMVector< WEMPrimitive >.
Definition at line 96 of file WEMContainer.h.
References mlrange_cast(), and T.
      
  | 
  defaultnoexcept | 
      
  | 
  override | 
Removes the given element from vector.
Note that this is done in O(1)!
Definition at line 156 of file WEMContainer.h.
References mlrange_cast().
      
  | 
  override | 
Replaces the given element at the given position, updates index.
Definition at line 144 of file WEMContainer.h.
References mlrange_cast().
Swaps elements and updates their indices.
Reimplemented from ml::WEMVector< WEMPrimitive >.
Definition at line 121 of file WEMContainer.h.
References mlrange_cast().