Package com.vaadin.experimental
Class FeatureFlags
java.lang.Object
com.vaadin.experimental.FeatureFlags
- All Implemented Interfaces:
Serializable
Tracks available feature flags and their status.
Enabled feature flags are stored in
vaadin-featureflags.properties inside the resources folder
(src/main/resources).- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classFeatureFlags wrapper class for storing the FeatureFlags object. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Featurestatic final Stringstatic final Featurestatic final StringDeprecated.static final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic FeatureFlagsget(VaadinContext context) Gets the FeatureFlags for the given Vaadin context.getEnableHelperMessage(Feature feature) Get a list of all available features and their status.booleanChecks if the given feature is enabled.booleanChecks if the given feature is enabled.voidRead the feature flag properties files and updates the enable property of each feature object.voidsetEnabled(String featureId, boolean enabled) Enables or disables the given feature.voidsetPropertiesLocation(File propertiesFolder) Set by the Maven / Gradle plugin when running through that so the feature flags will be correctly detected.
-
Field Details
-
PROPERTIES_FILENAME
- See Also:
-
SYSTEM_PROPERTY_PREFIX
Deprecated.UseSYSTEM_PROPERTY_PREFIX_EXPERIMENTALinstead.- See Also:
-
SYSTEM_PROPERTY_PREFIX_EXPERIMENTAL
- See Also:
-
EXAMPLE
-
COLLABORATION_ENGINE_BACKEND
-
FORM_FILLER_ADDON
-
COPILOT_EXPERIMENTAL
-
HILLA_FULLSTACK_SIGNALS
-
FLOW_FULLSTACK_SIGNALS
-
MASTER_DETAIL_LAYOUT_COMPONENT
-
REACT19
-
ACCESSIBLE_DISABLED_BUTTONS
-
LAYOUT_COMPONENT_IMPROVEMENTS
-
DEFAULT_AUTO_RESPONSIVE_FORM_LAYOUT
-
-
Constructor Details
-
FeatureFlags
Generate FeatureFlags with given lookup data.- Parameters:
lookup- lookup to use
-
-
Method Details
-
get
Gets the FeatureFlags for the given Vaadin context. If the Vaadin context has no FeatureFlags, a new instance is created and assigned to the context.- Parameters:
context- the vaadin context for which to get FeatureFlags from, notnull- Returns:
- a feature flags instance for the given context, not
null
-
setPropertiesLocation
Set by the Maven / Gradle plugin when running through that so the feature flags will be correctly detected. -
loadProperties
public void loadProperties()Read the feature flag properties files and updates the enable property of each feature object. -
getFeatures
Get a list of all available features and their status.- Returns:
- a list of all features
-
isEnabled
Checks if the given feature is enabled.- Parameters:
feature- the feature to check- Returns:
trueif enabled,falseotherwise
-
isEnabled
Checks if the given feature is enabled.- Parameters:
featureId- the feature to check- Returns:
trueif enabled,falseotherwise
-
setEnabled
Enables or disables the given feature.- Parameters:
featureId- the feature idenabled-trueto enable,falseto disable
-
getEnableHelperMessage
-
SYSTEM_PROPERTY_PREFIX_EXPERIMENTALinstead.