ExemplarCharacters.punctuation constructor
- Locale locale
Create an ExemplarCharacters for the "punctuation" set of exemplar characters for a given locale, using compiled data.
See the Rust documentation for try_new_punctuation
for more information.
Throws DataError on failure.
Implementation
factory ExemplarCharacters.punctuation(Locale locale) {
final result = _icu4x_ExemplarCharacters_create_punctuation_mv1(locale._ffi);
if (!result.isOk) {
throw DataError.values[result.union.err];
}
return ExemplarCharacters._fromFfi(result.union.ok, []);
}