VoCountries class abstract final

Country data used by the phone input and country picker.

The data is loaded on first use by the widgets that need it. Call load (or VoBootstrap.initialize(preloadCountries: true)) to load it up front before reading all or the lookups directly.

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

all → List<VoCountry>
no setter
isLoaded → bool
Whether the country data has been loaded.
no setter

Static Methods

byCode(String code) → VoCountry?
byContinent(String continent) → List<VoCountry>
byDialCode(String dialCode) → VoCountry?
byPhone(String phone, {Iterable<String> preferredCodes = const []}) → VoCountry?
The country whose dial code starts phone, a number in international format such as +447700900123.
favoriteCountries(BuildContext context) → List<VoCountry>
The countries in VoConfig.favoriteCountries, in that order.
load() → Future<void>
Loads the country data once. Concurrent calls share the same load.
Countries whose name, ISO code or dial code matches query.