Hashtable.this

Constructs a qualified hashtable that will use the provided allocator object. For immutable objects, a RCISharedAllocator must be supplied.

  1. this(A allocator)
    struct Hashtable(K, V)
    this
    (
    A
    this Q
    )
    if (
    !is(Q == shared) &&
    (
    is(A == RCISharedAllocator) ||
    !is(Q == immutable)
    )
    &&
    (
    is(A == RCIAllocator) ||
    is(A == RCISharedAllocator)
    )
    )
  2. this(U assocArr)
  3. this(A allocator, U assocArr)

Parameters

allocator A

Examples

import std.experimental.allocator : theAllocator, processAllocator;

auto h = Hashtable!(int, int)(theAllocator);
auto ch = const Hashtable!(int, int)(processAllocator);
auto ih = immutable Hashtable!(int, int)(processAllocator);

Meta