FeatureFlagConfigurationSetting Class

public final class FeatureFlagConfigurationSetting
extends ConfigurationSetting

FeatureFlagConfigurationSetting allows you to customize your own feature flags to dynamically administer a feature's lifecycle. Feature flags can be used to enable or disable features.

Field Summary

Modifier and Type Field and Description
static final String KEY_PREFIX

A prefix is used to construct a feature flag configuration setting's key.

Constructor Summary

Constructor Description
FeatureFlagConfigurationSetting(String featureId, boolean isEnabled)

The constructor for a feature flag configuration setting.

Method Summary

Modifier and Type Method and Description
FeatureFlagConfigurationSetting addClientFilter(FeatureFlagFilter clientFilter)

Add a feature flag filter to this configuration setting.

List<FeatureFlagFilter> getClientFilters()

Gets the feature flag filters of this configuration setting.

String getDescription()

Get the description of this configuration setting.

String getDisplayName()

Get the display name of this configuration setting.

String getFeatureId()

Get the feature ID of this configuration setting.

String getValue()

Gets the value of this configuration setting.

boolean isEnabled()

Get the boolean indicator to show if the setting is turn on or off.

FeatureFlagConfigurationSetting setClientFilters(List<FeatureFlagFilter> clientFilters)

Sets the feature flag filters of this configuration setting.

FeatureFlagConfigurationSetting setContentType(String contentType)

Sets the content type.

FeatureFlagConfigurationSetting setDescription(String description)

Set the description of this configuration setting.

FeatureFlagConfigurationSetting setDisplayName(String displayName)

Set the display name of this configuration setting.

FeatureFlagConfigurationSetting setETag(String etag)

Sets the ETag for this configuration setting.

FeatureFlagConfigurationSetting setEnabled(boolean isEnabled)

Set the boolean indicator to show if the setting is turn on or off.

FeatureFlagConfigurationSetting setFeatureId(String featureId)

Set the feature ID of this configuration setting.

FeatureFlagConfigurationSetting setKey(String key)

Sets the key of this setting.

FeatureFlagConfigurationSetting setLabel(String label)

Sets the label of this configuration setting.

FeatureFlagConfigurationSetting setTags(Map<String,String> tags)

Sets the tags for this configuration setting.

FeatureFlagConfigurationSetting setValue(String value)

Sets the value of this setting.

Methods inherited from ConfigurationSetting

Methods inherited from java.lang.Object

Field Details

KEY_PREFIX

public static final String KEY_PREFIX

A prefix is used to construct a feature flag configuration setting's key.

Constructor Details

FeatureFlagConfigurationSetting

public FeatureFlagConfigurationSetting(String featureId, boolean isEnabled)

The constructor for a feature flag configuration setting.

Parameters:

featureId - A feature flag identification value that used to construct in setting's key. The key of setting is KEY_PREFIX concatenate featureId.
isEnabled - A boolean value to turn on/off the feature flag setting.

Method Details

addClientFilter

public FeatureFlagConfigurationSetting addClientFilter(FeatureFlagFilter clientFilter)

Add a feature flag filter to this configuration setting.

Parameters:

clientFilter - a feature flag filter to add to this configuration setting.

Returns:

getClientFilters

public List getClientFilters()

Gets the feature flag filters of this configuration setting.

Returns:

the feature flag filters of this configuration setting.

getDescription

public String getDescription()

Get the description of this configuration setting.

Returns:

the description of this configuration setting.

getDisplayName

public String getDisplayName()

Get the display name of this configuration setting.

Returns:

the display name of this configuration setting.

getFeatureId

public String getFeatureId()

Get the feature ID of this configuration setting.

Returns:

the feature ID of this configuration setting.

getValue

public String getValue()

Gets the value of this configuration setting.

Overrides:

FeatureFlagConfigurationSetting.getValue()

isEnabled

public boolean isEnabled()

Get the boolean indicator to show if the setting is turn on or off.

Returns:

the boolean indicator to show if the setting is turn on or off.

setClientFilters

public FeatureFlagConfigurationSetting setClientFilters(List clientFilters)

Sets the feature flag filters of this configuration setting.

Parameters:

clientFilters - the feature flag filters of this configuration setting.

Returns:

setContentType

public FeatureFlagConfigurationSetting setContentType(String contentType)

Sets the content type. By default, the content type is null.

Overrides:

FeatureFlagConfigurationSetting.setContentType(String contentType)

Parameters:

contentType - The content type of this configuration setting.

Returns:

setDescription

public FeatureFlagConfigurationSetting setDescription(String description)

Set the description of this configuration setting.

Parameters:

description - the description of this configuration setting.

Returns:

setDisplayName

public FeatureFlagConfigurationSetting setDisplayName(String displayName)

Set the display name of this configuration setting.

Parameters:

displayName - the display name of this configuration setting.

Returns:

setETag

public FeatureFlagConfigurationSetting setETag(String etag)

Sets the ETag for this configuration setting.

Overrides:

FeatureFlagConfigurationSetting.setETag(String etag)

Parameters:

etag - The ETag for the configuration setting.

Returns:

setEnabled

public FeatureFlagConfigurationSetting setEnabled(boolean isEnabled)

Set the boolean indicator to show if the setting is turn on or off.

Parameters:

isEnabled - the boolean indicator to show if the setting is turn on or off.

Returns:

setFeatureId

public FeatureFlagConfigurationSetting setFeatureId(String featureId)

Set the feature ID of this configuration setting.

Parameters:

featureId - the feature ID of this configuration setting.

Returns:

setKey

public FeatureFlagConfigurationSetting setKey(String key)

Sets the key of this setting.

Overrides:

FeatureFlagConfigurationSetting.setKey(String key)

Parameters:

key - The key to associate with this configuration setting.

Returns:

setLabel

public FeatureFlagConfigurationSetting setLabel(String label)

Sets the label of this configuration setting. #NO_LABEL is the default label used when this value is not set.

Overrides:

FeatureFlagConfigurationSetting.setLabel(String label)

Parameters:

label - The label of this configuration setting.

Returns:

setTags

public FeatureFlagConfigurationSetting setTags(Map tags)

Sets the tags for this configuration setting.

Overrides:

FeatureFlagConfigurationSetting.setTags(Map<String,String> tags)

Parameters:

tags - The tags to add to this configuration setting.

Returns:

setValue

public FeatureFlagConfigurationSetting setValue(String value)

Sets the value of this setting.

Overrides:

FeatureFlagConfigurationSetting.setValue(String value)

Parameters:

value - The value to associate with this configuration setting.

Returns:

Applies to