Locale class

The Locale data structure represents a geographical region or location.

Constructors

Locale({required String country, String? subdivision})
Locale.fromJson(Map<String, dynamic> json)
factory

Properties

country String
The country of the locale. Must be a valid ISO 3166 country code. For example, the code US refers to the United States of America.
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
subdivision String?
The state or subdivision of the locale. A valid ISO 3166-2 subdivision code. For example, the code WA refers to the state of Washington.
final

Methods

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

Operators

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