Class NameStoreCache
Stores a mapping from names to ids.

Defined in <seqan/misc/misc_name_store_cache.h>
Signature template <typename TNameStore[, typename TName]> class NameStoreCache;

Template Parameters

TNameStore The type to use for the name store. Usually a StringSet.
TName The type to use for the names. Defaults to Value<TNameStore>::Type.

Member Function Overview

Interface Function Overview

Member Functions Detail

NameStoreCache::NameStoreCache(nameStore);

Constructor

Parameters

nameStore The name store to manage the cache for.

Interface Functions Detail

void appendName(nameStore, name, cache);

Append a name to a name store and register it in the cache.

Parameters

nameStore The name store to append the name to.
name The name to append to the store.
cache The NameStoreCache to use for faster access.

bool getIdByName(nameStore, name, idx[, cache]);

Get id/index of a string in a name store using a NameStoreCache.

Parameters

nameStore The name store to search the name in (TNameStore).
name The name to search in the name store (Value of TNameStore).
idx The variable to store the id/index at (IntegerConcept).
cache The NameStoreCache to use for speeding up the lookup. If omitted then a linear search is used.

Returns

bool true if the name could be found and false otherwise.

void refresh(cache);

Recreate a NameStoreCache.

Parameters

nameStore The NameStoreCache to refresh.