BDE 4.14.0 Production release
|
#include <bdlb_caselessstringviewhash.h>
Public Types | |
typedef bsl::string_view | argument_type |
typedef bsl::size_t | result_type |
typedef void | is_transparent |
Type alias indicating this is a transparent hash functor. | |
Public Member Functions | |
BSLMF_NESTED_TRAIT_DECLARATION (CaselessStringViewHash, bsl::is_trivially_copyable) | |
BSLMF_NESTED_TRAIT_DECLARATION (CaselessStringViewHash, bsl::is_trivially_default_constructible) | |
CaselessStringViewHash ()=default | |
Create a CaselessStringViewHash object. | |
CaselessStringViewHash (const CaselessStringViewHash &original)=default | |
~CaselessStringViewHash ()=default | |
Destroy this object. | |
CaselessStringViewHash & | operator= (const CaselessStringViewHash &rhs)=default |
bsl::size_t | operator() (bsl::string_view argument) const |
This struct
defines a hash operation for string views enabling bsl::string
s or bsl::string_view
s to be used as keys in the standard unordered associative containers such as bsl::unordered_map
and bsl::unordered_set
. Note that this class is an empty POD type.
typedef void bdlb::CaselessStringViewHash::is_transparent |
typedef bsl::size_t bdlb::CaselessStringViewHash::result_type |
|
default |
|
default |
Create a CaselessStringViewHash
object. Note that as CaselessStringViewHash
is an empty (stateless) type, this operation will have no observable effect.
|
default |
bdlb::CaselessStringViewHash::BSLMF_NESTED_TRAIT_DECLARATION | ( | CaselessStringViewHash | , |
bsl::is_trivially_copyable | |||
) |
bdlb::CaselessStringViewHash::BSLMF_NESTED_TRAIT_DECLARATION | ( | CaselessStringViewHash | , |
bsl::is_trivially_default_constructible | |||
) |
bsl::size_t bdlb::CaselessStringViewHash::operator() | ( | bsl::string_view | argument | ) | const |
Return a hash code generated from the contents of the specified null-terminated argument
string, cast to lower case. The behavior is undefined unless argument
points to a null-terminated string.
|
default |
Assign to this object the value of the specified rhs
object, and a return a reference providing modifiable access to this object. Note that as CaselessStringViewHash
is an empty (stateless) type, this operation will have no observable effect.