-
- All Implemented Interfaces:
-
java.util.Map.Entry
public final class FeatureFlag implements Map.Entry<String, String>
-
-
Constructor Summary
Constructors Constructor Description FeatureFlag(String name)Create a named {@code FeatureFlag}with no variantFeatureFlag(String name, String variant)Create a new {@code FeatureFlag}with a name and (optionally) a variant.FeatureFlag(Map.Entry<String, String> mapEntry)Create a new {@code FeatureFlag}based on an existing{@code Map.Entry}.
-
Method Summary
Modifier and Type Method Description StringgetName()StringgetVariant()StringgetKey()Same as getName. StringgetValue()Same as getVariant. StringsetValue(@Nullable() String value)Throws {@code UnsupportedOperationException}as{@code FeatureFlag}is considered immutable.inthashCode()booleanequals(Object other)StringtoString()-
-
Constructor Detail
-
FeatureFlag
FeatureFlag(String name)
Create a named{@code FeatureFlag}with no variant- Parameters:
name- the identifying name of the new{@code FeatureFlag}(not{@code null})
-
FeatureFlag
FeatureFlag(String name, String variant)
Create a new{@code FeatureFlag}with a name and (optionally) a variant.- Parameters:
name- the identifying name of the new{@code FeatureFlag}(not{@code null})variant- the feature variant
-
-
Method Detail
-
getVariant
@Nullable() String getVariant()
-
getValue
@Nullable() String getValue()
Same as getVariant.
-
setValue
@Nullable() String setValue(@Nullable() String value)
Throws
{@code UnsupportedOperationException}as{@code FeatureFlag}is considered immutable.- Parameters:
value- ignored
-
hashCode
int hashCode()
-
-
-
-