aGrUM  0.20.3
a C++ library for (probabilistic) graphical models
gum::HashTableConst Class Reference

Parameters specifying the default behavior of the hashtables. More...

#include <agrum/tools/core/hashTable.h>

+ Collaboration diagram for gum::HashTableConst:

Static Public Attributes

static constexpr Size default_size {Size(4)}
 The default number of slots in hashtables. More...
 
static constexpr Size default_mean_val_by_slot {Size(3)}
 The average number of elements admissible by slots. More...
 
static constexpr bool default_resize_policy {true}
 A Boolean indicating whether inserting too many values into the hashtable makes it resize itself automatically. More...
 
static constexpr bool default_uniqueness_policy {true}
 A Boolean indicating the default behavior when trying to insert more than once elements with identical keys. More...
 

Detailed Description

Parameters specifying the default behavior of the hashtables.

Definition at line 72 of file hashTable.h.

Member Data Documentation

◆ default_mean_val_by_slot

constexpr Size gum::HashTableConst::default_mean_val_by_slot {Size(3)}
static

The average number of elements admissible by slots.

Once this number is reached, the size of the hashtable is automatically doubled if we are in automatic resize mode.

Definition at line 86 of file hashTable.h.

◆ default_resize_policy

constexpr bool gum::HashTableConst::default_resize_policy {true}
static

A Boolean indicating whether inserting too many values into the hashtable makes it resize itself automatically.

true = automatic, false = manual.

Definition at line 93 of file hashTable.h.

◆ default_size

constexpr Size gum::HashTableConst::default_size {Size(4)}
static

The default number of slots in hashtables.

By default, hashtables can store up to thrice the number of slots elements before their size is increased To each slot corresponds a chained list of elements with the same hashed key.

Definition at line 79 of file hashTable.h.

◆ default_uniqueness_policy

constexpr bool gum::HashTableConst::default_uniqueness_policy {true}
static

A Boolean indicating the default behavior when trying to insert more than once elements with identical keys.

true = do not insert the elements but the first one and throw an exception after the first insertion; false = insert the elements without complaining.

Definition at line 101 of file hashTable.h.


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