LocationInfo class
Geographic location information for an IP address.
Constructors
- LocationInfo({required String country, required String countryCode, required String city, required String state, required String zipcode, required double latitude, required double longitude, required String timezone, required String localtime})
- Creates a new location information object.
-
LocationInfo.fromJson(Map<
String, dynamic> json) -
Creates a LocationInfo from a JSON object.
factory
Properties
- city → String
-
City name
final
- country → String
-
Country name
final
- countryCode → String
-
Two-letter country code (ISO 3166-1 alpha-2)
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- latitude → double
-
Latitude coordinate
final
- localtime → String
-
Local time at the location
final
- longitude → double
-
Longitude coordinate
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- state → String
-
State or region name
final
- timezone → String
-
Timezone identifier (e.g., "America/New_York")
final
- zipcode → String
-
Postal or ZIP code
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Converts this LocationInfo to a JSON object.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited