FirebaseAnalyticsWeb class

Web implementation of FirebaseAnalyticsPlatform

Inheritance
  • Object
  • PlatformInterface
  • FirebaseAnalyticsWeb

Constructors

FirebaseAnalyticsWeb({FirebaseApp? app})
Builds an instance of FirebaseAnalyticsWeb with an optional FirebaseApp instance If app is null then the created instance will use the default FirebaseApp

Properties

app → FirebaseApp
Returns the FirebaseApp for the current instance.
no setterinherited
appInstance ↔ FirebaseApp?
The FirebaseApp this instance was initialized with.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

delegateFor({FirebaseApp? app}) → FirebaseAnalyticsPlatform
Enables delegates to create new instances of themselves
getAppInstanceId() Future<String?>
Retrieves the app instance id from the service.
getSessionId() Future<int?>
initiateOnDeviceConversionMeasurement({String? emailAddress, String? phoneNumber}) Future<void>
Used for ads conversion measurement, without allowing any personally identifiable information to leave the user device.
inherited
isSupported() Future<bool>
isSupported() informs web users whether the browser supports Firebase.Analytics
logEvent({required String name, Map<String, Object?>? parameters, AnalyticsCallOptions? callOptions}) Future<void>
Logs a custom Flutter Analytics event with the given name and event parameters.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resetAnalyticsData() Future<void>
Clears all analytics data for this app from the device and resets the app instance id.
setAnalyticsCollectionEnabled(bool enabled) Future<void>
Sets whether analytics collection is enabled for this app.
setConsent({bool? adStorageConsentGranted, bool? analyticsStorageConsentGranted, bool? adPersonalizationSignalsConsentGranted, bool? adUserDataConsentGranted, bool? functionalityStorageConsentGranted, bool? personalizationStorageConsentGranted, bool? securityStorageConsentGranted}) Future<void>
Sets the applicable end user consent state. By default, no consent mode values are set.
setCurrentScreen({String? screenName, String? screenClassOverride, AnalyticsCallOptions? callOptions}) Future<void>
Sets the current screen name, which specifies the current visual context in your app.
setDefaultEventParameters(Map<String, Object?>? defaultParameters) Future<void>
Adds parameters that will be set on every event logged from the SDK, including automatic ones.
setSessionTimeoutDuration(Duration timeout) Future<void>
Sets the duration of inactivity that terminates the current session.
setUserId({String? id, AnalyticsCallOptions? callOptions}) Future<void>
Sets the user id. Setting a null id removes the user id. callOptions are for web platform only.
setUserProperty({required String name, required String? value, AnalyticsCallOptions? callOptions}) Future<void>
Sets a user property to the given value. Setting a null value removes the user property. callOptions are for web platform only.
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

registerWith(Registrar registrar) → void
Called by PluginRegistry to register this plugin for Flutter Web