[#BloombergLP-bslalg-HashTableBucket] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslalg.adoc[bslalg]::HashTableBucket :relfileprefix: ../../ :mrdocs: == Synopsis Declared in `<bslalg_hashtablebucket.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- struct HashTableBucket; ---- == Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslalg/HashTableBucket/countElements.adoc[`countElements`] | Return the number of nodes in this hash bucket. | xref:BloombergLP/bslalg/HashTableBucket/end.adoc[`end`] | Return the next node after the end of this bucket, or 0 if `0 == last()`, so the range to traverse to traverse all nodes in the bucket is always `[ first(), end() )]` regardless of whether the bucket is empty. | xref:BloombergLP/bslalg/HashTableBucket/first.adoc[`first`] | Return the address of the first element in this hash bucket, or a null pointer value if the bucket is empty. | xref:BloombergLP/bslalg/HashTableBucket/last.adoc[`last`] | Return the address of the last element in this hash bucket, or a null pointer value if the bucket is empty. | xref:BloombergLP/bslalg/HashTableBucket/reset.adoc[`reset`] | Set `first` and `last` to a null pointer value. | xref:BloombergLP/bslalg/HashTableBucket/setFirst.adoc[`setFirst`] | Set the `first` element of this bucket to the specified `node`. The behavior is undefined unless `node` is an element from the same bidirectional list as the `last` element in this bucket, and `node` either precedes `last` in that list, or is the same node, or this bucket is empty and `node` has a null pointer value. | xref:BloombergLP/bslalg/HashTableBucket/setFirstAndLast.adoc[`setFirstAndLast`] | Set `first` and `last` to the specified values. Behavior is undefined unless unless `first == last`, or unless `first` and `last` are links from the same list, where `first` precedes `last` in the list. Note that `first` and `last` may both have a null pointer value, indicating an empty bucket. | xref:BloombergLP/bslalg/HashTableBucket/setLast.adoc[`setLast`] | Set the `last` element of this bucket to the specified `node`. The behavior is undefined unless `node` is an element from the same bidirectional list as the `first` element in this bucket, and `node` either follows `first` in that list, or is the same node, or this bucket is empty and `node` has a null pointer value. | xref:BloombergLP/bslalg/HashTableBucket/2conversion.adoc[`operator BloombergLP::bslmf::NestedTraitDeclaration<HashTableBucket, IsBitwiseCopyable>`] | Declare `HashTableBucket` as bitwise copyable. |=== == Data Members [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslalg/HashTableBucket/d_first_p.adoc[`d_first_p`] | Address of the first node in this bucket, or 0 if empty. | xref:BloombergLP/bslalg/HashTableBucket/d_last_p.adoc[`d_last_p`] | Address of the last node in this bucket, or 0 if empty. |=== == Non-Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslalg/operator_not_eq-0a.adoc[`operator!=`] | Return `true` if the specified hash table buckets `lhs` and `rhs` are not equivalent and `false` otherwise. | xref:BloombergLP/bslalg/operator_eq-0ed.adoc[`operator==`] | Return `true` if the specified hash table buckets `lhs` and `rhs` are equivalent and `false` otherwise. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#