# Whole Container Operations

Safety

These operations must not be invoked concurrently on the same instance of `enumerable_thread_specific`.

The following table provides additional information on the members of this template class.
Member | Description
--- | ---
enumerable_thread_specific() | Constructs an `enumerable_thread_specific` where each local copy will be default constructed.
enumerable_thread_specific(const enumerable_thread_specific &other) | Copy construct an `enumerable_thread_specific`. The values are copy constructed from the values in `other` and have same thread correspondence.
template<typename U, typename Alloc, ets_key_usage_type Cachetype> enumerable_thread_specific( const enumerable_thread_specific<U, Alloc, Cachetype>& other ) | Copy construct an `enumerable_thread_specific`. The values are copy constructed from the values in `other` and have same thread correspondence.
template< typename Finit> enumerable_thread_specific(Finit finit) | Constructs `enumerable_thread_specific` such that any thread-local element will be created by copying the result of `finit()`. ### Note The expression `finit()` must be safe to evaluate concurrently by multiple threads. It is evaluated each time a thread-local element is created.
enumerable_thread_specific(const &exemplar) | Constructs an `enumerable_thread_specific` where each local copy will be copy constructed from `exemplar`.
~enumerable_thread_specific() | Destroys all elements in `*this`. Destroys any native TLS keys that were created for this instance.
enumerable_thread_specific& operator=(const enumerable_thread_specific& other); | Sets `*this` to be a copy of `other`.
template< typename U, typename Alloc, ets_key_usage_type Cachetype> enumerable_thread_specific& operator=(const enumerable_thread_specific<U, Alloc, Cachetype>& other); | Sets `*this` to be a copy of `other`. ### Note The allocator and key usage specialization is unchanged by this call.
void clear() | Destroys all elements in `*this`. Destroys and then recreates any native TLS keys used in the implementation. ### Note In the current implementation, there is no performance advantage of using clear instead of destroying and reconstructing an `enumerable_thread_specific`.

Parent topic: enumerable_thread_specific Template Class