Package co.featbit.commons.model
Class AllFlagStates<T>
java.lang.Object
co.featbit.commons.model.BasicFlagState
co.featbit.commons.model.AllFlagStates<T>
- Type Parameters:
T- String/Boolean/Numeric Type
- All Implemented Interfaces:
Serializable
The object provides a standard return responding the request of getting all flag values from a client sdk
- See Also:
-
Field Summary
Fields inherited from class co.featbit.commons.model.BasicFlagState
message, success -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAllFlagStates(boolean success, String message, List<EvalDetail<T>> data) -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> AllFlagStates<T>build a AllFlagStates without flag valuebooleanstatic <T> AllFlagStates<T>build a AllFlagStates from jsonreturn a detail of a given flag key namegetData()return details of all the flagsinthashCode()static <T> AllFlagStates<T>of(boolean success, String message, List<EvalDetail<T>> data) build a AllFlagStatestoString()Methods inherited from class co.featbit.commons.model.BasicFlagState
getMessage, isSuccess, jsonfy
-
Constructor Details
-
AllFlagStates
-
-
Method Details
-
empty
build a AllFlagStates without flag value- Parameters:
message- the reason without flag value- Returns:
- a AllFlagStates
-
of
build a AllFlagStates- Type Parameters:
T- String/Boolean/Numeric Type- Parameters:
success- true if the last request is successfulmessage- the reasondata- all flag values- Returns:
- a AllFlagStates
-
fromJson
build a AllFlagStates from json- Type Parameters:
T- String/Boolean/Numeric Type- Parameters:
json- a string jsoncls-- Returns:
- a AllFlagStates
-
getData
return details of all the flags- Returns:
- a map of flag key name and the
Functionto get the itsEvalDetail
-
get
return a detail of a given flag key name- Parameters:
flagKeyName- flag key name- Returns:
- an
EvalDetail
-
toString
-
equals
-
hashCode
public int hashCode()
-