ATLAS Offline Software
|
Indexing policy for a set-like container. More...
#include <SetIndexingPolicy.h>
Public Types | |
typedef SET::value_type | ElementType |
The type we get when we dereference a link, and derived types. More... | |
typedef SET::const_reference | ElementConstReference |
typedef SET::const_pointer | ElementConstPointer |
typedef SET::key_type | index_type |
The type of an index, as provided to or returned from a link. More... | |
typedef SG::IndexHolder< index_type > | stored_index_type |
The type of an index, as stored internally within a link. More... | |
Static Public Member Functions | |
static bool | isValid (const stored_index_type &index) |
Test to see if an index is valid. More... | |
static index_type | storedToExternal (stored_index_type index) |
Convert from stored to external index types. More... | |
static void | reset (stored_index_type &index) |
Make an index invalid. More... | |
static ElementType | lookup (const stored_index_type &index, const SET &data) |
Retrieve from a container the element corresponding to an index. More... | |
static void | reverseLookup (const SET &data, ElementConstReference element, index_type &same) |
Find the index of the (first) instance of ELEMENT in DATA. More... | |
Private Types | |
typedef SET::reference | reference |
typedef SET::iterator | iterator |
Private Member Functions | |
BOOST_CONCEPT_ASSERT ((boost::SimpleAssociativeContainerConcept< SET >)) | |
Indexing policy for a set-like container.
See ElementLinkTraits.h for a summary of the requirements for an indexing policy.
Indexes here are use IndexHolder, with the key of the container as the payload.
Definition at line 46 of file SetIndexingPolicy.h.
typedef SET::const_pointer SG::SetIndexingPolicy< SET >::ElementConstPointer |
Definition at line 59 of file SetIndexingPolicy.h.
typedef SET::const_reference SG::SetIndexingPolicy< SET >::ElementConstReference |
Definition at line 58 of file SetIndexingPolicy.h.
typedef SET::value_type SG::SetIndexingPolicy< SET >::ElementType |
The type we get when we dereference a link, and derived types.
Definition at line 57 of file SetIndexingPolicy.h.
typedef SET::key_type SG::SetIndexingPolicy< SET >::index_type |
The type of an index, as provided to or returned from a link.
Definition at line 62 of file SetIndexingPolicy.h.
|
private |
Definition at line 53 of file SetIndexingPolicy.h.
|
private |
Definition at line 52 of file SetIndexingPolicy.h.
typedef SG::IndexHolder<index_type> SG::SetIndexingPolicy< SET >::stored_index_type |
The type of an index, as stored internally within a link.
Definition at line 65 of file SetIndexingPolicy.h.
|
private |
|
static |
Test to see if an index is valid.
index | The index to test. |
|
static |
Retrieve from a container the element corresponding to an index.
index | The index to fetch. |
data | The container. |
Will throw SG::ExcInvalidIndex if the index is invalid and SG::ExcIndexNotFound if the index is not in the container.
|
static |
Make an index invalid.
index[out] | The index to reset. |
|
static |
Find the index of the (first) instance of ELEMENT in DATA.
data | The container to search. |
element | The element to find. |
index[out] | The index in the container of element . |
Throws SG::ExcElementNotFound if the element is not in the container.
|
static |
Convert from stored to external index types.
index | The stored index. |