public class GeneralOptions extends AnalyticsOptions
| Modifier and Type | Method and Description |
|---|---|
GeneralOptions |
anonymizeIp(boolean anonymizeIp)
Optional.
|
GeneralOptions |
dataSource(String dataSource)
Optional.
|
GeneralOptions |
disableTask(Task task)
Disables a task.
|
GeneralOptions |
forceSsl(boolean forceSsl)
Optional.
|
GeneralOptions |
useBeacon(boolean useBeacon)
Optional.
|
appTrackingOptions, contentOptions, createOptions, customDimensionsAndMetricsOptions, customsOptions, eventsOptions, exceptionOptions, experimentsOptions, generalOptions, go, go, goAndLog, hitOptions, socialOptions, systemOptions, timingOptions, trafficSourcesOptionspublic GeneralOptions anonymizeIp(boolean anonymizeIp)
When present, the IP address of the sender will be anonymized.
Default Value: Nonetruepublic GeneralOptions forceSsl(boolean forceSsl)
By default, tracking beacons sent from https pages will be sent using https while beacons sent from http pages will be sent using http. Setting forceSSL to true will force http pages to also send all beacons using https.
Default Value: truetruepublic GeneralOptions useBeacon(boolean useBeacon)
Setting this to true, will instruct the client to use navigator.sendBeacon to send the hit. This is useful in cases where you wish to track an event just before a user navigates away from your site, without delaying the navigation. If the browser does not support navigator.sendBeacon, the hit will be sent normally.
Default Value: falsetruepublic GeneralOptions dataSource(String dataSource)
Indicates the data source of the hit. Hits sent from analytics.js will have data source set to 'web'; hits sent from one of the mobile SDKs will have data source set to 'app'.
Default Value: None'crm'public GeneralOptions disableTask(Task task)
Disables a task. see: Analytics Tasks
If you are serving Analytics from a non http or https site,
eg because you are building a native app you need to disable
the Task.CHECK_PROTOCOL task
Copyright © 2015. All Rights Reserved.