ICU 75.1 75.1

Public Member Functions | Friends
icu::message2::data_model::UnsupportedStatement::Builder Class Reference

The mutable `UnsupportedStatement::Builder` class allows the statement to be constructed incrementally. More...

`#include <messageformat2_data_model.h>`

Inheritance diagram for icu::message2::data_model::UnsupportedStatement::Builder:

## Public Member Functions
Builder & | setKeyword (const UnicodeString &k)
| Sets the keyword of this statement. More...
Builder & | setBody (Reserved &&r)
| Sets the body of this statement. More...
Builder & | addExpression (Expression &&e, UErrorCode &status)
| Adds an expression to this statement. More...
UnsupportedStatement | build (UErrorCode &status) const
| Constructs a new immutable `UnsupportedStatement` using the keyword, body and (if applicable) expressions that were previously set. More...
| Builder (UErrorCode &status)
| Default constructor. More...
virtual | ~Builder ()
| Destructor. More...
| Builder (const Builder &)=delete
Builder & | operator= (const Builder &)=delete
| Builder (Builder &&)=delete
Builder & | operator= (Builder &&)=delete

## Friends
class | UnsupportedStatement
class | message2::Parser

## Detailed Description

The mutable `UnsupportedStatement::Builder` class allows the statement to be constructed incrementally.

Builder is not copyable or movable.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

Definition at line 1814 of file messageformat2_data_model.h.

## Constructor & Destructor Documentation

## ◆ Builder()

icu::message2::data_model::UnsupportedStatement::Builder::Builder | ( | UErrorCode & | status | ) |

Default constructor.

Returns a Builder with no keyword or body set.

Parameters

  status | Input/output error code.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

## ◆ ~Builder()

virtual icu::message2::data_model::UnsupportedStatement::Builder::~Builder | ( |  | ) |
| virtual

Destructor.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

## Member Function Documentation

## ◆ addExpression()

Builder& icu::message2::data_model::UnsupportedStatement::Builder::addExpression | ( | Expression && | e,
|  | UErrorCode & | status
| ) |  |

Adds an expression to this statement.

Parameters

  e | The expression to add. Passed by move.
  status | Input/output error code.

Returns
  A reference to the builder.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

## ◆ build()

UnsupportedStatement icu::message2::data_model::UnsupportedStatement::Builder::build | ( | UErrorCode & | status | ) | const

Constructs a new immutable `UnsupportedStatement` using the keyword, body and (if applicable) expressions that were previously set.

If `setKeyword()` was never called, then `status` is set to U_INVALID_STATE_ERROR. If `setBody()` was never called, the body is treated as absent (not an error). If `addExpression()` was not called at least once, then `status` is set to U_INVALID_STATE_ERROR.

The builder object (`this`) can still be used after calling `build()`.

Parameters

  status | Input/output error code.

Returns
  The new UnsupportedStatement

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

## ◆ setBody()

Builder& icu::message2::data_model::UnsupportedStatement::Builder::setBody | ( | Reserved && | r | ) |

Sets the body of this statement.

Parameters

  r | The `Reserved` annotation to set as the body. Passed by move.

Returns
  A reference to the builder.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

## ◆ setKeyword()

Builder& icu::message2::data_model::UnsupportedStatement::Builder::setKeyword | ( | const UnicodeString & | k | ) |

Sets the keyword of this statement.

Parameters

  k | The keyword to set.

Returns
  A reference to the builder.

Internal:
  Do not use. This API is for internal use only. ICU 75 technology preview

Deprecated:
  This API is for technology preview only.

The documentation for this class was generated from the following file:

- i18n/unicode/messageformat2_data_model.h