37template<
class Key,
class Hash>
38template<
class InputIter>
46 if (!this->capacity())
56 return insert(first, last);
62template<
class Key,
class Hash>
72template<
class Key,
class Hash>
81template<
class Key,
class Hash>
91template<
class Key,
class Hash>
96 insert(list.begin(), list.end());
100template<
class Key,
class Hash>
101template<
class AnyType,
class AnyHash>
109 for (
auto iter = tbl.
cbegin(); iter != tbl.
cend(); ++iter)
118template<
class Key,
class Hash>
119template<
class InputIter>
127 while (first != last)
139template<
class Key,
class Hash>
142 std::initializer_list<Key> list
145 return insert(list.begin(), list.end());
149template<
class Key,
class Hash>
160template<
class Key,
class Hash>
170template<
class Key,
class Hash>
181template<
class Key,
class Hash>
182template<
class InputIter>
189 return this->parent_type::erase(first, last);
193template<
class Key,
class Hash>
196 std::initializer_list<Key> list
199 return unset(list.begin(), list.end());
203template<
class Key,
class Hash>
210 return unset(list.
begin(), list.
end());
214template<
class Key,
class Hash>
220 return unset(list.
begin(), list.
end());
224template<
class Key,
class Hash>
231 return unset(list.
begin(), list.
end());
237template<
class Key,
class Hash>
240 return this->
found(key);
244template<
class Key,
class Hash>
247 return this->
found(key);
251template<
class Key,
class Hash>
259template<
class Key,
class Hash>
266template<
class Key,
class Hash>
269 assignMany(rhs.size(), rhs.begin(), rhs.end());
273template<
class Key,
class Hash>
277 if (this->size() != rhs.
size())
284 if (!this->
found(iter.key()))
294template<
class Key,
class Hash>
301template<
class Key,
class Hash>
315template<
class Key,
class Hash>
319 this->parent_type::retain(rhs);
324template<
class Key,
class Hash>
331 if (this->
found(iter.key()))
333 this->
erase(iter.key());
345template<
class Key,
class Hash>
349 return this->operator|=(rhs);
353template<
class Key,
class Hash>
357 this->parent_type::erase(rhs);
365template<
class Key,
class Hash>
374template<
class Key,
class Hash>
387template<
class Key,
class Hash>
396 for (
const Key&
k : a)
408template<
class Key,
class Hash>
411 const HashSet<Key, Hash>& a,
412 const HashSet<Key, Hash>&
b
415 HashSet<Key, Hash> result(a);
421template<
class Key,
class Hash>
424 const HashSet<Key, Hash>& a,
425 const HashSet<Key, Hash>&
b
428 HashSet<Key, Hash> result(a.
capacity());
430 for (
const Key&
k : a)
444template<
class Key,
class Hash>
455template<
class Key,
class Hash>
466template<
class Key,
class Hash>
477template<
class Key,
class Hash>
485template<
class Key,
class Hash>
493template<
class Key,
class Hash>
A 1D vector of objects of type <T> with a fixed length <N>.
static constexpr label size() noexcept
Return the number of elements in the FixedList.
iterator end() noexcept
Return an iterator to end traversing the FixedList.
iterator begin() noexcept
Return an iterator to begin traversing the FixedList.
A HashTable with keys but without contents that is similar to std::unordered_set.
bool operator[](const Key &key) const noexcept
Return true if the entry exists, same as found().
bool insert(const Key &key)
Insert a new entry, not overwriting existing entries.
this_type & operator|=(const this_type &rhs)
Add entries to this HashSet.
typename parent_type::key_iterator iterator
An iterator, returning reference to the key.
typename parent_type::const_key_iterator const_iterator
A const_iterator, returning reference to the key.
const_iterator cbegin() const
constexpr const_iterator cend() const noexcept
HashSet()
Default construct with default (128) table capacity.
this_type & operator-=(const this_type &rhs)
Remove entries from this HashSet. Uses erase()
this_type & operator&=(const this_type &rhs)
Only retain entries found in both HashSets.
this_type & operator^=(const this_type &rhs)
Only retain unique entries (xor)
void operator=(const this_type &rhs)
Copy assign.
this_type & operator+=(const this_type &rhs)
Add entries to this HashSet. Same as the '|=' operator.
A HashTable similar to std::unordered_map.
Ostream & writeKeys(Ostream &os, const label shortLen=0) const
iterator begin()
iterator set to the beginning of the HashTable
const_iterator cbegin() const
const_iterator set to the beginning of the HashTable
label capacity() const noexcept
The size of the underlying table.
label size() const noexcept
The number of elements in table.
constexpr const_iterator cend() const noexcept
const_iterator to signal the end (for any HashTable)
Base for lists with indirect addressing, templated on the list contents type and the addressing type....
iterator end()
Return an iterator at end of list.
iterator begin()
Return an iterator at begin of list.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
bool found(const T &val, label pos=0) const
True if the value if found in the list.
iterator begin() noexcept
Return an iterator to begin traversing the UList.
iterator end() noexcept
Return an iterator to end traversing the UList.
void size(const label n)
Older name for setAddressableSize.
Ostream & operator()() const
Output stream (master only).
friend bool operator!=(const refineCell &rc1, const refineCell &rc2)
friend bool operator==(const refineCell &rc1, const refineCell &rc2)
patchWriters resize(patchIds.size())
OBJstream os(runTime.globalPath()/outputName)
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
srcOptions insert("case", fileName(rootDirSource/caseDirSource))
Number of items before requiring line-breaks in the list output.