gatb.core-API-0.0.0
|
Implementation of the Container interface. More...
#include <ContainerSet.hpp>
Public Member Functions | |
ContainerSet (dp::Iterator< Item > *it) | |
bool | contains (const Item &item) |
Public Member Functions inherited from Container< Item > | |
virtual | ~Container () |
Public Member Functions inherited from ISmartPointer | |
virtual | ~ISmartPointer () |
Public Member Functions inherited from SmartPointer | |
void | use () |
void | forget () |
Additional Inherited Members | |
Protected Member Functions inherited from SmartPointer | |
SmartPointer () | |
virtual | ~SmartPointer () |
Implementation of the Container interface.
This implementation uses a sorted vector for the 'contains' method. It implies a binary_search (log(N) complexity)
|
inline |
Constructor.
[in] | it | : iterator over the items of the container. They are all inserted in the vector and the vector is then sorted. |
|
inlinevirtual |
Tells whether an item exists or not
Implements Container< Item >.