ICU 76.1 76.1
|
The SelectorKeys
class represents the key list for a single variant.
More...
#include <messageformat2_data_model.h>
Data Structures | |
class | Builder |
The mutable SelectorKeys::Builder class allows the key list to be constructed one key at a time. More... | |
Public Member Functions | |
std::vector< Key > | getKeys () const |
Returns the underlying list of keys. | |
bool | operator< (const SelectorKeys &other) const |
Less than operator. | |
SelectorKeys () | |
Default constructor. | |
SelectorKeys (const SelectorKeys &other) | |
Copy constructor. | |
SelectorKeys & | operator= (SelectorKeys other) noexcept |
Assignment operator. | |
virtual | ~SelectorKeys () |
Destructor. | |
![]() | |
virtual | ~UObject () |
Destructor. | |
virtual UClassID | getDynamicClassID () const |
ICU4C "poor man's RTTI", returns a UClassID for the actual ICU class. | |
Friends | |
class | Builder |
class | message2::Checker |
class | message2::MessageFormatter |
class | message2::Serializer |
void | swap (SelectorKeys &s1, SelectorKeys &s2) noexcept |
Non-member swap function. | |
The SelectorKeys
class represents the key list for a single variant.
It corresponds to the keys
array in the Variant
interface defined in https://github.com/unicode-org/message-format-wg/blob/main/spec/data-model.md#messages
SelectorKeys
is immutable, copyable and movable.
Definition at line 516 of file messageformat2_data_model.h.
|
inline |
Default constructor.
Puts the SelectorKeys into a valid but undefined state.
Definition at line 615 of file messageformat2_data_model.h.
Referenced by operator<(), operator=(), SelectorKeys(), swap, and ~SelectorKeys().
icu::message2::data_model::SelectorKeys::SelectorKeys | ( | const SelectorKeys & | other | ) |
Copy constructor.
References SelectorKeys().
|
virtual |
Destructor.
References SelectorKeys().
|
inline |
Returns the underlying list of keys.
SelectorKeys
object previously failed.Definition at line 528 of file messageformat2_data_model.h.
bool icu::message2::data_model::SelectorKeys::operator< | ( | const SelectorKeys & | other | ) | const |
Less than operator.
Compares the two key lists lexicographically. This method makes it possible for a SelectorKeys
to be used as a map key, which allows variants to be represented as a map. It is not expected to be useful otherwise.
other | The SelectorKeys to compare to this one. |
this
is less than other
, comparing the two key lists lexicographically. Returns false otherwise.References SelectorKeys().
|
noexcept |
Assignment operator.
References SelectorKeys().
|
friend |
Definition at line 652 of file messageformat2_data_model.h.
|
friend |
Definition at line 653 of file messageformat2_data_model.h.
|
friend |
Definition at line 654 of file messageformat2_data_model.h.
|
friend |
Definition at line 655 of file messageformat2_data_model.h.
|
friend |
Non-member swap function.
s1 | will get s2's contents |
s2 | will get s1's contents |
Definition at line 624 of file messageformat2_data_model.h.
References SelectorKeys(), and swap.
Referenced by swap.