Debian Codegraph @

intl/icu_capi/bindings/js/ICU4XRegionDisplayNames.d.ts

raw
1 import { FFIError } from "./diplomat-runtime"
2 import { ICU4XDataProvider } from "./ICU4XDataProvider";
3 import { ICU4XError } from "./ICU4XError";
4 import { ICU4XLocale } from "./ICU4XLocale";
5
6 /**
7
8 * See the {@link https://docs.rs/icu/latest/icu/displaynames/struct.RegionDisplayNames.html Rust documentation for `RegionDisplayNames`} for more information.
9 */
10 export class ICU4XRegionDisplayNames {
11
12 /**
13
14 * Creates a new `RegionDisplayNames` from locale data and an options bag.
15
16 * See the {@link https://docs.rs/icu/latest/icu/displaynames/struct.RegionDisplayNames.html#method.try_new Rust documentation for `try_new`} for more information.
17 * @throws {@link FFIError}<{@link ICU4XError}>
18 */
19 static create(provider: ICU4XDataProvider, locale: ICU4XLocale): ICU4XRegionDisplayNames | never;
20
21 /**
22
23 * Returns the locale specific display name of a region. Note that the function returns an empty string in case the display name for a given region code is not found.
24
25 * See the {@link https://docs.rs/icu/latest/icu/displaynames/struct.RegionDisplayNames.html#method.of Rust documentation for `of`} for more information.
26 * @throws {@link FFIError}<{@link ICU4XError}>
27 */
28 of(region: string): string | never;
29 }