STXXL  1.4-dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
stxxl::hash_map::iterator_map< HashMap > Class Template Reference

Detailed Description

template<class HashMap>
class stxxl::hash_map::iterator_map< HashMap >

Definition at line 27 of file iterator.h.

+ Inheritance diagram for stxxl::hash_map::iterator_map< HashMap >:
+ Collaboration diagram for stxxl::hash_map::iterator_map< HashMap >:

Classes

struct  hasher
 

Public Types

typedef
hash_map_type::external_size_type 
external_size_type
 
typedef HashMap hash_map_type
 
typedef
hash_map_type::internal_size_type 
internal_size_type
 
typedef hash_map_iterator_base
< hash_map_type
iterator_base
 
typedef hash_map_type::key_type key_type
 
typedef hash_map_type::node_type node_type
 
typedef hash_map_type::source_type source_type
 

Public Member Functions

 iterator_map (hash_map_type *map)
 
 ~iterator_map ()
 
void fix_iterators_2end (internal_size_type i_bucket, const key_type &key)
 Update iterators with given key and bucket and make them point to the end of the hash-map (called by erase and erase_oblivious) More...
 
void fix_iterators_2ext (internal_size_type i_bucket_old, const key_type &key, internal_size_type i_bucket_new, external_size_type i_ext)
 Update iterators with given key and bucket and make them point to the specified location in external memory (will be called during re-hashing) More...
 
void fix_iterators_2int (internal_size_type i_bucket, const key_type &key, node_type *node)
 Update iterators with given key and bucket and make them point to the specified node in internal memory (will be called by insert_oblivious) More...
 
void fix_iterators_all2end ()
 Update all iterators and make them point to the end of the hash-map (used by clear()) More...
 
void print_statistics (std::ostream &o=std::cout) const
 
void register_iterator (iterator_base &it)
 
void register_iterator (iterator_base &it, internal_size_type i_bucket)
 
void swap (iterator_map< HashMap > &obj)
 
void unregister_iterator (iterator_base &it)
 
void unregister_iterator (iterator_base &it, internal_size_type i_bucket)
 

Private Types

typedef
multimap_type::const_iterator 
const_mmiterator_type
 
typedef multimap_type::iterator mmiterator_type
 
typedef compat_hash_multimap
< internal_size_type,
iterator_base *, hasher >
::result 
multimap_type
 
typedef multimap_type::value_type pair_type
 bucket-index and pointer to iterator_base More...
 

Private Member Functions

template<class OutputContainer >
void _find (internal_size_type i_bucket, OutputContainer &outc)
 Find all iterators registered with given bucket and add them to outc. More...
 
void change_hash_map_pointers (hash_map_type *map)
 
- Private Member Functions inherited from stxxl::noncopyable
 noncopyable ()
 

Private Attributes

multimap_type it_map_
 
hash_map_typemap_
 

Member Typedef Documentation

template<class HashMap>
typedef multimap_type::const_iterator stxxl::hash_map::iterator_map< HashMap >::const_mmiterator_type
private

Definition at line 72 of file iterator_map.h.

template<class HashMap>
typedef hash_map_type::external_size_type stxxl::hash_map::iterator_map< HashMap >::external_size_type

Definition at line 37 of file iterator_map.h.

template<class HashMap>
typedef HashMap stxxl::hash_map::iterator_map< HashMap >::hash_map_type

Definition at line 31 of file iterator_map.h.

template<class HashMap>
typedef hash_map_type::internal_size_type stxxl::hash_map::iterator_map< HashMap >::internal_size_type

Definition at line 36 of file iterator_map.h.

Definition at line 39 of file iterator_map.h.

template<class HashMap>
typedef hash_map_type::key_type stxxl::hash_map::iterator_map< HashMap >::key_type

Definition at line 34 of file iterator_map.h.

template<class HashMap>
typedef multimap_type::iterator stxxl::hash_map::iterator_map< HashMap >::mmiterator_type
private

Definition at line 71 of file iterator_map.h.

template<class HashMap>
typedef compat_hash_multimap< internal_size_type, iterator_base*, hasher >::result stxxl::hash_map::iterator_map< HashMap >::multimap_type
private

Definition at line 66 of file iterator_map.h.

template<class HashMap>
typedef hash_map_type::node_type stxxl::hash_map::iterator_map< HashMap >::node_type

Definition at line 32 of file iterator_map.h.

template<class HashMap>
typedef multimap_type::value_type stxxl::hash_map::iterator_map< HashMap >::pair_type
private

bucket-index and pointer to iterator_base

Definition at line 70 of file iterator_map.h.

template<class HashMap>
typedef hash_map_type::source_type stxxl::hash_map::iterator_map< HashMap >::source_type

Definition at line 33 of file iterator_map.h.

Constructor & Destructor Documentation

template<class HashMap>
stxxl::hash_map::iterator_map< HashMap >::iterator_map ( hash_map_type map)
inline

Definition at line 78 of file iterator_map.h.

template<class HashMap>
stxxl::hash_map::iterator_map< HashMap >::~iterator_map ( )
inline

Definition at line 82 of file iterator_map.h.

Member Function Documentation

template<class HashMap>
template<class OutputContainer >
void stxxl::hash_map::iterator_map< HashMap >::_find ( internal_size_type  i_bucket,
OutputContainer &  outc 
)
inlineprivate

Find all iterators registered with given bucket and add them to outc.

Definition at line 220 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::change_hash_map_pointers ( hash_map_type map)
inlineprivate

Definition at line 230 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::fix_iterators_2end ( internal_size_type  i_bucket,
const key_type key 
)
inline
template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::fix_iterators_2ext ( internal_size_type  i_bucket_old,
const key_type key,
internal_size_type  i_bucket_new,
external_size_type  i_ext 
)
inline

Update iterators with given key and bucket and make them point to the specified location in external memory (will be called during re-hashing)

Definition at line 127 of file iterator_map.h.

Referenced by stxxl::hash_map::hash_map< KeyType, MappedType, HashType, CompareType, SubBlockSize, SubBlocksPerBlock, AllocType >::_rebuild_buckets(), and stxxl::hash_map::hash_map< KeyType, MappedType, HashType, CompareType, SubBlockSize, SubBlocksPerBlock, AllocType >::insert().

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::fix_iterators_2int ( internal_size_type  i_bucket,
const key_type key,
node_type node 
)
inline

Update iterators with given key and bucket and make them point to the specified node in internal memory (will be called by insert_oblivious)

Definition at line 160 of file iterator_map.h.

Referenced by stxxl::hash_map::hash_map< KeyType, MappedType, HashType, CompareType, SubBlockSize, SubBlocksPerBlock, AllocType >::find(), and stxxl::hash_map::hash_map< KeyType, MappedType, HashType, CompareType, SubBlockSize, SubBlocksPerBlock, AllocType >::insert_oblivious().

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::fix_iterators_all2end ( )
inline

Update all iterators and make them point to the end of the hash-map (used by clear())

Definition at line 206 of file iterator_map.h.

Referenced by stxxl::hash_map::hash_map< KeyType, MappedType, HashType, CompareType, SubBlockSize, SubBlocksPerBlock, AllocType >::clear().

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::print_statistics ( std::ostream &  o = std::cout) const
inline
template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::register_iterator ( iterator_base it)
inline

Definition at line 87 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::register_iterator ( iterator_base it,
internal_size_type  i_bucket 
)
inline

Definition at line 92 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::swap ( iterator_map< HashMap > &  obj)
inline

Definition at line 237 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::unregister_iterator ( iterator_base it)
inline

Definition at line 98 of file iterator_map.h.

template<class HashMap>
void stxxl::hash_map::iterator_map< HashMap >::unregister_iterator ( iterator_base it,
internal_size_type  i_bucket 
)
inline

Definition at line 103 of file iterator_map.h.

Member Data Documentation

template<class HashMap>
multimap_type stxxl::hash_map::iterator_map< HashMap >::it_map_
private

Definition at line 75 of file iterator_map.h.

template<class HashMap>
hash_map_type* stxxl::hash_map::iterator_map< HashMap >::map_
private

Definition at line 74 of file iterator_map.h.


The documentation for this class was generated from the following files: