public final class FeatureToggle
extends java.lang.Object
Whiteboard
and can be
discovered by third party code to control the state of feature toggles.Constructor and Description |
---|
FeatureToggle(java.lang.String name,
java.util.concurrent.atomic.AtomicBoolean state)
Create a new adapter with a given name and value.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getName() |
boolean |
isEnabled() |
boolean |
setEnabled(boolean state)
Changes the state of the feature toggle.
|
public FeatureToggle(java.lang.String name, java.util.concurrent.atomic.AtomicBoolean state)
name
- the name of the feature toggle.state
- the state for the feature toggle.public java.lang.String getName()
public boolean isEnabled()
public boolean setEnabled(boolean state)
state
- the new state of the feature toggle.Copyright © 2012–2022 The Apache Software Foundation. All rights reserved.