Region class

The class Region is a Dart class that represents a region. It has properties such as date, didEnter, identifier, latitude, longitude, radius, fromPositionDetection, eventName, and spentTime. It also has a constructor that initializes these properties, and a static method jsonToObj that converts a JSON object to an instance of the Region class.

Constructors

Region(int date, bool didEnter, String identifier, double latitude, double longitude, double radius, bool fromPositionDetection, String eventName, int spentTime)
The Region() constructor is initializing the properties of the Region class with the provided arguments. It takes in the following arguments in order: date, didEnter, identifier, latitude, longitude, radius, fromPositionDetection, eventName, and spentTime.

Properties

date int
int date; is declaring a property named date of type int in the Region class. This property will hold the date value for a specific region.
getter/setter pair
didEnter bool
bool didEnter; is declaring a property named didEnter of type bool in the Region class. This property will hold a boolean value indicating whether the region was entered or not.
getter/setter pair
eventName String
String eventName; is declaring a property named eventName of type String in the Region class. This property will hold a string value representing the name of an event associated with a specific region.
getter/setter pair
fromPositionDetection bool
bool fromPositionDetection; is declaring a property named fromPositionDetection of type bool in the Region class. This property will hold a boolean value indicating whether the region was detected from a position detection mechanism or not.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
identifier String
String identifier; is declaring a property named identifier of type String in the Region class. This property will hold a string value that represents the identifier of a specific region.
getter/setter pair
latitude double
double latitude; is declaring a property named latitude of type double in the Region class. This property will hold a double value representing the latitude coordinate of a specific region.
getter/setter pair
longitude double
double longitude; is declaring a property named longitude of type double in the Region class. This property will hold a double value representing the longitude coordinate of a specific region.
getter/setter pair
radius double
double radius; is declaring a property named radius of type double in the Region class. This property will hold a double value representing the radius of a specific region.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
spentTime int
int spentTime; is declaring a property named spentTime of type int in the Region class. This property will hold an integer value representing the amount of time spent in a specific region.
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) Region
The function converts a JSON object into a Region object in Dart. @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 Region class.