ICU 76.1 76.1
|
The mutable Pattern::Builder
class allows the pattern to be constructed one part at a time.
More...
#include <messageformat2_data_model.h>
Public Member Functions | |
Builder & | add (Expression &&part, UErrorCode &status) noexcept |
Adds a single expression part to the pattern. | |
Builder & | add (Markup &&part, UErrorCode &status) noexcept |
Adds a single markup part to the pattern. | |
Builder & | add (UnicodeString &&part, UErrorCode &status) noexcept |
Adds a single text part to the pattern. | |
Pattern | build (UErrorCode &status) const noexcept |
Constructs a new immutable Pattern using the list of parts set with previous add() calls. | |
Builder (UErrorCode &status) | |
Default constructor. | |
virtual | ~Builder () |
Destructor. | |
Builder (const Builder &)=delete | |
Builder & | operator= (const Builder &)=delete |
Builder (Builder &&)=delete | |
Builder & | operator= (Builder &&)=delete |
Friends | |
class | Pattern |
The mutable Pattern::Builder
class allows the pattern to be constructed one part at a time.
Builder is not copyable or movable.
Definition at line 1715 of file messageformat2_data_model.h.
icu::message2::data_model::Pattern::Builder::Builder | ( | UErrorCode & | status | ) |
Default constructor.
Returns a Builder with an empty sequence of PatternParts.
status | Input/output error code |
Referenced by add(), add(), add(), and ~Builder().
|
virtual |
Destructor.
References Builder().
|
noexcept |
Adds a single expression part to the pattern.
part | The part to be added (passed by move) |
status | Input/output error code. |
References Builder().
|
noexcept |
Adds a single markup part to the pattern.
part | The part to be added (passed by move) |
status | Input/output error code. |
References Builder().
|
noexcept |
Adds a single text part to the pattern.
Copies part
.
part | The part to be added (passed by move) |
status | Input/output error code. |
References Builder().
|
noexcept |
Constructs a new immutable Pattern
using the list of parts set with previous add()
calls.
The builder object (this
) can still be used after calling build()
.
status | Input/output error code. |
|
friend |
Definition at line 1717 of file messageformat2_data_model.h.