NoOpAnalytics class

An implementation that will never send events.

This is for clients that opt to either not send analytics, or will migrate to use AnalyticsImpl at a later time.

Implemented types

Constructors

NoOpAnalytics()
const

Properties

clientId String
The shared identifier for Flutter and Dart related tooling using package:unified_analytics.
no setteroverride
getConsentMessage String
Retrieves the consent message to prompt users with on first run or when the message has been updated.
final
hashCode int
The hash code for this object.
no setterinherited
okToSend bool
Returns true if it is OK to send an analytics message. Do not cache, as this depends on factors that can change, such as the configuration file contents.
final
parsedTools Map<String, ToolInfo>
Returns a map object with all of the tools that have been parsed out of the configuration file.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shouldShowMessage bool
Boolean that lets the client know if they should display the message.
final
telemetryEnabled bool
Boolean indicating whether or not telemetry is enabled.
final
userPropertyMap Map<String, Map<String, Object?>>
Returns a map representation of the UserProperty for the Analytics instance.
final

Methods

clientShowedMessage() → void
Method to be invoked by the client using this package to confirm that the client has shown the message and that it can be added to the config file and start sending events the next time it starts up.
override
close({int delayDuration = kDelayDuration}) Future<void>
Call this method when the tool using this package is closed.
override
fetchAvailableSurveys() Future<List<Survey>>
Method to fetch surveys from the endpoint kContextualSurveyUrl.
override
logFileStats() LogFileStats?
Query the persisted event data stored on the user's machine.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
send(Event event) Future<Response>?
Send preconfigured events using specific named constructors on the Event class.
override
setTelemetry(bool reportingBool) Future<void>
Pass a boolean to either enable or disable telemetry and make the necessary changes in the persisted configuration file.
override
suppressTelemetry() → void
Calling this will result in telemetry collection being suppressed for the current invocation.
override
surveyInteracted({required Survey survey, required SurveyButton surveyButton}) → void
Method to run after interacting with a Survey instance.
override
surveyShown(Survey survey) → void
Method to be called after a survey has been shown to the user.
override
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

staticClientId String
The hard-coded client ID value for each NoOp instance.
no setter