AFlagsFeatureFlag
public
class
AFlagsFeatureFlag
extends Object
| java.lang.Object | |
| ↳ | com.android.tradefed.util.flag.AFlagsFeatureFlag |
A feature flag description, as parsed from `aflags list`.
Summary
Public constructors | |
|---|---|
AFlagsFeatureFlag(String flagString)
Default constructor. |
|
AFlagsFeatureFlag(String flagName, AFlagsFeatureFlag.State currentState, AFlagsFeatureFlag.State pendingState, AFlagsFeatureFlag.Setter setter, AFlagsFeatureFlag.Mutability mutability, String container)
Constructor to create a new |
|
Public methods | |
|---|---|
String
|
getContainer()
Returns the container for this flag. |
AFlagsFeatureFlag.State
|
getCurrentState()
Returns the current state of this flag (e.g. |
String
|
getFlagName()
Returns tne full name of the flag (e.g. com.mypackage.foo_flag). |
AFlagsFeatureFlag.Mutability
|
getMutability()
Returns whether this flag can be dynamically set. |
AFlagsFeatureFlag.State
|
getPendingState()
Returns the pending state of the flag (i.e. |
AFlagsFeatureFlag.Setter
|
getSetter()
Returns what last caused this flag value to change. |
String
|
toString()
|
Public constructors
AFlagsFeatureFlag
public AFlagsFeatureFlag (String flagString)
Default constructor.
| Parameters | |
|---|---|
flagString |
String: A single line from aflags list, e.g. com.my.flag enabled
(->disabled) local read-write system. |
AFlagsFeatureFlag
public AFlagsFeatureFlag (String flagName,
AFlagsFeatureFlag.State currentState,
AFlagsFeatureFlag.State pendingState,
AFlagsFeatureFlag.Setter setter,
AFlagsFeatureFlag.Mutability mutability,
String container)Constructor to create a new AFlagsFeatureFlag with the given properties.
| Parameters | |
|---|---|
flagName |
String: The full name of the flag. |
currentState |
AFlagsFeatureFlag.State: The current state of the flag. |
pendingState |
AFlagsFeatureFlag.State: The pending state of the flag. |
setter |
AFlagsFeatureFlag.Setter: Where the flag was last set from. |
mutability |
AFlagsFeatureFlag.Mutability: Whether the flag is mutable. |
container |
String: The container for this flag. |
Public methods
getContainer
public String getContainer ()
Returns the container for this flag.
| Returns | |
|---|---|
String |
|
getCurrentState
public AFlagsFeatureFlag.State getCurrentState ()
Returns the current state of this flag (e.g. State.ENABLED or State.DISABLED.
Will not return State.NONE.
| Returns | |
|---|---|
AFlagsFeatureFlag.State |
|
getFlagName
public String getFlagName ()
Returns tne full name of the flag (e.g. com.mypackage.foo_flag).
| Returns | |
|---|---|
String |
|
getMutability
public AFlagsFeatureFlag.Mutability getMutability ()
Returns whether this flag can be dynamically set.
| Returns | |
|---|---|
AFlagsFeatureFlag.Mutability |
|
getPendingState
public AFlagsFeatureFlag.State getPendingState ()
Returns the pending state of the flag (i.e. what it will be set to after a reboot). May
return State.NONE if there is no state pending.
| Returns | |
|---|---|
AFlagsFeatureFlag.State |
|
getSetter
public AFlagsFeatureFlag.Setter getSetter ()
Returns what last caused this flag value to change.
| Returns | |
|---|---|
AFlagsFeatureFlag.Setter |
|
toString
public String toString ()
| Returns | |
|---|---|
String |
|