GeneralCategoryNameToMaskMapper constructor

GeneralCategoryNameToMaskMapper(
  1. DataProvider provider
)

See the Rust documentation for GeneralCategoryGroup for more information.

Throws DataError on failure.

Implementation

factory GeneralCategoryNameToMaskMapper(DataProvider provider) {
  final result = _icu4x_GeneralCategoryNameToMaskMapper_load_mv1(provider._ffi);
  if (!result.isOk) {
    throw DataError.values[result.union.err];
  }
  return GeneralCategoryNameToMaskMapper._fromFfi(result.union.ok, []);
}