Source code
Revision control
Copy as Markdown
Other Tools
// generated by diplomat-tool
import type { DataError } from "./DataError"
import type { DataProvider } from "./DataProvider"
import type { DisplayNamesOptions } from "./DisplayNamesOptions"
import type { DisplayNamesOptions_obj } from "./DisplayNamesOptions"
import type { Locale } from "./Locale"
import type { LocaleParseError } from "./LocaleParseError"
import type { pointer, codepoint } from "./diplomat-runtime.d.ts";
/**
* See the [Rust documentation for `RegionDisplayNames`](https://docs.rs/icu/latest/icu/experimental/displaynames/struct.RegionDisplayNames.html) for more information.
*/
export class RegionDisplayNames {
get ffiValue(): pointer;
/**
* Creates a new `RegionDisplayNames` from locale data and an options bag using a particular data source.
*
* See the [Rust documentation for `try_new`](https://docs.rs/icu/latest/icu/experimental/displaynames/struct.RegionDisplayNames.html#method.try_new) for more information.
*/
static createWithProvider(provider: DataProvider, locale: Locale, options: DisplayNamesOptions_obj): RegionDisplayNames;
/**
* 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.
*
* See the [Rust documentation for `of`](https://docs.rs/icu/latest/icu/experimental/displaynames/struct.RegionDisplayNames.html#method.of) for more information.
*/
of(region: string): string;
constructor(locale: Locale, options: DisplayNamesOptions_obj);
}