Poi class
The class Poi
is a Dart class that represents a Point of Interest (POI). It has various properties
such as jsonData
, city
, idstore
, name
, date
, distance
, duration
, latitude
,
locationid
, longitude
, zipcode
, radius
, address
, countrycode
, tags
, types
, and
contact
.
Constructors
- Poi(Object jsonData, String? city, String idstore, String name, int date, double? distance, String duration, double latitude, String locationid, double longitude, String? zipcode, int radius, String? address, String? countrycode, String? tags, String? types, String? contact)
-
The
Poi()
constructor is initializing a new instance of thePoi
class with the provided values for its properties. The constructor takes in arguments for each property of thePoi
class and assigns them to the corresponding property using thethis
keyword. This allows you to create a newPoi
object and set its properties in a single line of code. -
Poi.named({required Object jsonData, required String idstore, required String name, required int date, required String duration, required double latitude, required String locationid, required double longitude, required int radius, String? city, double? distance, String? zipcode, String? address, String? countrycode, String? tags, String? types, String? contact, Map<
String, dynamic> ? userProperties}) -
The
Poi.named()
constructor is initializing a new instance of thePoi
class with the provided values for its properties. The constructor takes in arguments for each property of thePoi
class and assigns them to the corresponding property using thethis
keyword. This allows you to create a newPoi
object and set its properties in a single line of code.
Properties
- address ↔ String?
-
String address;
is declaring a property namedaddress
of typeString
in thePoi
class. This property will hold the address information of a Point of Interest (POI) object.getter/setter pair - city ↔ String?
-
String city;
is declaring a property namedcity
of typeString
in thePoi
class. This property will hold the city information of a Point of Interest (POI) object.getter/setter pair - contact ↔ String?
-
String contact;
is declaring a property namedcontact
of typeString
in thePoi
class. This property will hold the contact information of a Point of Interest (POI) object.getter/setter pair - countrycode ↔ String?
-
String countrycode;
is declaring a property namedcountrycode
of typeString
in thePoi
class. This property will hold the country code information of a Point of Interest (POI) object.getter/setter pair - date ↔ int
-
The line
int date;
is declaring a property nameddate
of typeint
in thePoi
class. This property will hold the date information of a Point of Interest (POI) object.getter/setter pair - distance ↔ double?
-
The line
double? distance;
is declaring a property nameddistance
of typedouble
in thePoi
class. Thedouble?
indicates that thedistance
property can hold a decimal number or a null value. The?
denotes that the property is nullable, meaning it can be assigned a null value.getter/setter pair - duration ↔ String
-
String duration;
is declaring a property namedduration
of typeString
in thePoi
class. This property will hold the duration information of a Point of Interest (POI) object.getter/setter pair - hashCode → int
-
The hash code for this object.
no setterinherited
- idstore ↔ String
-
String idstore;
is declaring a property namedidstore
of typeString
in thePoi
class. This property will hold the idstore information of a Point of Interest (POI) object.getter/setter pair - jsonData ↔ Object
-
The
Object jsonData;
is declaring a property namedjsonData
of typeObject
in thePoi
class. This property can hold any type of object.getter/setter pair - latitude ↔ double
-
double latitude;
is declaring a property namedlatitude
of typedouble
in thePoi
class. This property will hold the latitude information of a Point of Interest (POI) object. Thedouble
type indicates that the latitude value can be a decimal number.getter/setter pair - locationid ↔ String
-
String locationid;
is declaring a property namedlocationid
of typeString
in thePoi
class. This property will hold the location ID information of a Point of Interest (POI) object.getter/setter pair - longitude ↔ double
-
double longitude;
is declaring a property namedlongitude
of typedouble
in thePoi
class. This property will hold the longitude information of a Point of Interest (POI) object. Thedouble
type indicates that the longitude value can be a decimal number.getter/setter pair - name ↔ String
-
String name;
is declaring a property namedname
of typeString
in thePoi
class. This property will hold the name information of a Point of Interest (POI) object.getter/setter pair - radius ↔ int
-
int radius;
is declaring a property namedradius
of typeint
in thePoi
class. This property will hold the radius information of a Point of Interest (POI) object. Theint
type indicates that the radius value will be an integer.getter/setter pair - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
String tags;
is declaring a property namedtags
of typeString
in thePoi
class. This property will hold the tags information of a Point of Interest (POI) object.getter/setter pair - types ↔ String?
-
String types;
is declaring a property namedtypes
of typeString
in thePoi
class. This property will hold the types information of a Point of Interest (POI) object.getter/setter pair -
userProperties
↔ Map<
String, dynamic> ? -
This attribute holds the custom properties of a Point of Interest (POI) object.
getter/setter pair
- zipcode ↔ String?
-
String zipcode;
is declaring a property namedzipcode
of typeString
in thePoi
class. This property will hold the zipcode information of a Point of Interest (POI) object.getter/setter pair
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 Methods
-
jsonToObj(
Map< String, dynamic> json) → Poi -
The function
jsonToObj
takes a JSON object and returns aPoi
object with the corresponding properties. @param {Map<String, dynamic>} json - A map containing key-value pairs where the keys are strings and the values can be of any type. @returns an instance of the Poi class.