Static Public Member Functions

container_erasure_dispatcher< KeyType, DataType, ObjectIdentificationTag, KeyDispatchTag, StorageTag > Struct Template Reference

A dispatch facility that unwraps type-erasued key-value type pairs. More...

#include <data_container.hpp>

Static Public Member Functions

template<typename ContainerType , typename IdType >
static void erase (ContainerType &cont, IdType const &id, KeyType const &key)
 Erase data for a particular key.
template<typename ContainerType , typename IdType >
static void erase (ContainerType &cont, IdType const &id)
 Erase all data associated with keys of the supplied type for the object.

Detailed Description

template<typename KeyType, typename DataType, typename ObjectIdentificationTag, typename KeyDispatchTag, typename StorageTag>
struct viennadata::traits::container_erasure_dispatcher< KeyType, DataType, ObjectIdentificationTag, KeyDispatchTag, StorageTag >

A dispatch facility that unwraps type-erasued key-value type pairs.

Refer to Alexandrescu, "Modern C++ Design" for details on type erasure

Template Parameters:
KeyType The type of the key used for access
DataType Type of the data that is stored for the element
ObjectType The type of the object the data is associated with
ObjectIdentificationTag Determines the dispatch mechanism for objects the data is associated with. Either 'pointer_based_id' (the default) or 'object_provided_id' (requires suitable overload of 'object_identifier')
KeyDispatchTag Determines the method for key dispatch (either full dispatch ('full_KeyDispatchTag', default) or dispatch based on key type 'type_KeyDispatchTag')
StorageTag Specifies dense ('dense_data_tag') or sparse ('storage_data_tag', default) storage of data. The former requires element-identification by id, cf. class 'object_identifier'

Member Function Documentation

static void erase ( ContainerType &  cont,
IdType const &  id,
KeyType const &  key 
) [inline, static]

Erase data for a particular key.

static void erase ( ContainerType &  cont,
IdType const &  id 
) [inline, static]

Erase all data associated with keys of the supplied type for the object.


The documentation for this struct was generated from the following file: