PostalCode class
Represents a postal code with associated location data.
Used for postal code lookup, address autocomplete, and validation. Contains geographic and administrative information for a postal code.
- Annotations
Constructors
Properties
- accuracy → double?
-
Accuracy of the coordinates (in meters)
final
- city → String?
-
City or locality name
final
- code → String
-
The postal code value (e.g., '90210', 'SW1A 1AA', 'M5H 2N2')
final
- countryCode → String
-
Country code (ISO 3166-1 alpha-2)
final
- county → String?
-
County or district name
final
-
extensions
→ Map<
String, dynamic> ? -
finalinherited
- hasCoordinates → bool
-
Returns true if this postal code has valid geographic coordinates
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- latitude → double?
-
Geographic latitude coordinate
final
- longitude → double?
-
Geographic longitude coordinate
final
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- state → String?
-
State, province, or region name
final
- stateCode → String?
-
State/province code
final
- stringify → bool?
-
If set to
true, thetoStringmethod will be overridden to output this instance'sprops.no setterinherited - timezone → String?
-
Timezone identifier (e.g., 'America/Los_Angeles')
final
Methods
-
copyWith(
{String? code, String? countryCode, String? city, String? state, String? stateCode, String? county, double? latitude, double? longitude, String? timezone, double? accuracy, Map< String, dynamic> ? extensions}) → PostalCode -
getExtension<
T> (String key) → T? -
inherited
-
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