EventSpa class

Annotations
  • @HiveType(typeId: 0)

Constructors

EventSpa.new({String? latitude, String? longitude, String? libraryVersion, String? ipAddress, String? userId, String? sessionId, String? counterId, String? appScreen, String? appVersion, required String? eventType, String? deviceId, String? appName, String? deviceName, String? osVersion, String? osName, String? platform, String? language, String? resolutionWidth, String? resolutionHeight, Map<String, dynamic>? customParam, String? id, String? uriSand})
const
EventSpa.appException({required String fatal, required String engagementTimeMSec})
Use this constructor is app fatal error and crash app fatal is the error message engagementTimeMSec is the time in milliseconds, the user was engaged with the app
EventSpa.appSessionEnd()
Use this constructor is destroy the app
const
EventSpa.appSessionStart()
Use this constructor is open the app
const
EventSpa.appUpdate({required String previousAppVersion})
Use this constructor is end user update the app previousAppVersion is the previous version of the app
EventSpa.custom({required String eventType, required Map<String, dynamic> customParam})
Use this constructor need create custom event eventType is the event type customParam is the custom parameter
EventSpa.error({required String error, required String errorValue})
Use this constructor is app error error is the error message errorValue is the error value
Use this constructor is user click link and open the file Open file is current regular: pdf|xlsx?|docx?|txt|rtf|csv|exe|key|pp(s|t|tx)|7z|pkg|rar|gz|zip|avi|mov|mp4|mpe?g|wmv|midi?|mp3|wav|wma linkUri is the link that was opened linkId is the link id linkText is the link text linkDomain is the link domain linkClassed is the link classed fileName is the file name fileExtension is the file extension
EventSpa.firstOpen({required String previousGmpAppId, required String updatedWithAnalytics, required String previousFirstOpenCount, required String systemApp, required String systemAppUpdate, required String deferredAnalyticsCollection, required String resetAnalyticsCause, required String engagementTimeMSec})
Use this constructor is user first open the app previousGmpAppId is the previous gmp app id updatedWithAnalytics is the updated with analytics previousFirstOpenCount is the previous first open count systemApp is the system app systemAppUpdate is the system app update deferredAnalyticsCollection is the deferred analytics collection resetAnalyticsCause is the reset analytics cause engagementTimeMsec is the time in milliseconds, the user was engaged with the app
EventSpa.fromJson(String source)
Convert the json string to EventSpa
factory
EventSpa.linkOpened({required String linkUri})
Use this constructor is user click and open the link linkUri is the link that was opened
EventSpa.screenView({required String pageLocation, required String pageReferrer})
Use this constructor is user open screen pageLocation is new screen uri pageReferrer is old screen uri
EventSpa.scroll(String engagementTimeMSec)
Use this constructor is user scroll engagementTimeMSec is the time in milliseconds, the user was engaged with the app user first time reach the bottom of the screen
EventSpa.search({required String value})
Use this constructor is user search value is the search value

Properties

appName String?
The name of the app
final
appScreen String?
The screen of the app The screen is the current screen that the user is on Example: /home, /profile/settings
final
appVersion String?
The version of the app
final
counterId String?
Unique counter id, counter get from the SPA service
final
customParam Map<String, dynamic>?
The custom parameter of the event
final
deviceId String?
The device id
final
deviceName String?
The name of the device
final
eventType String?
The type of the event Example: app_exception, link_opened
final
hashCode int
The hash code for this object.
no setterinherited
id String?
final
ipAddress String?
The IP address of the user Use the NetworkRequest.getIpAddress to get the IP address Use service https://api64.ipify.org Need permission internet
final
language String?
The language code of the device
final
latitude String?
The latitude and longitude of the user's location Need permission location
final
libraryVersion String?
The version of the library
final
longitude String?
The latitude and longitude of the user's location Need permission location
final
osName String?
The name of the OS
final
osVersion String?
The version of the OS
final
platform String?
The platform of the device
final
resolutionHeight String?
The height of the screen
final
resolutionWidth String?
The width of the screen
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sessionId String?
The session id created when the app is opened and destroyed when the app is closed
final
toJson → dynamic
Convert this EventSpa to a json object
no setter
toJsonString String
Convert this EventSpa to a json string
no setter
uriSand String?
final
userId String?
Unique user id is auth service
final

Methods

copyWith(EventSpa event) EventSpa
CopyWith the current EventSpa with the new values event is the new values Return the new EventSpa If the value is null, the old value will be used If the value is not null, the new value will be used
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMap() Map<String, dynamic>
toString() String
A string representation of this object.
inherited

Operators

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