Enum Class EnableGoogleAnalytics.SendMode
java.lang.Object
java.lang.Enum<EnableGoogleAnalytics.SendMode>
org.vaadin.googleanalytics.tracking.EnableGoogleAnalytics.SendMode
- All Implemented Interfaces:
Serializable, Comparable<EnableGoogleAnalytics.SendMode>, Constable
- Enclosing class:
EnableGoogleAnalytics
Send mode settings that can be configured through
EnableGoogleAnalytics.sendMode().-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAlways send tracked page views and events to Google Analytics.Never send tracked page views and events to Google Analytics.Send tracked page views and events to Google Analytics only when Vaadin is run in production mode. -
Method Summary
Modifier and TypeMethodDescriptionabstract booleanshouldSend(boolean productionMode) Checks whether sending should be enabled for the given production mode setting.Returns the enum constant of this class with the specified name.static EnableGoogleAnalytics.SendMode[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ALWAYS
Always send tracked page views and events to Google Analytics. -
PRODUCTION
Send tracked page views and events to Google Analytics only when Vaadin is run in production mode. This is the default setting. -
NEVER
Never send tracked page views and events to Google Analytics.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
shouldSend
public abstract boolean shouldSend(boolean productionMode) Checks whether sending should be enabled for the given production mode setting.- Parameters:
productionMode- the production mode setting- Returns:
- whether sending should be enabled
-