Package com.microsoft.graph.serializer
Class EnumSetSerializer
java.lang.Object
com.microsoft.graph.serializer.EnumSetSerializer
Serializes and deserializes EnumSets
The Graph service expects a single enum value as a comma-delimited string
Here, we flatten the EnumSet to serialize the object
and insert the response into an array to deserialize back to an EnumSet
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
EnumSetSerializer
Not available for instantiation- Parameters:
logger- logger to use during serialization
-
-
Method Details
-
deserialize
Deserializes a comma-delimited string of enum values- Parameters:
type- the typejsonStrToDeserialize- the string to deserialize- Returns:
- EnumSet of values
-
serialize
Serializes an EnumSet into a comma-delimited string- Parameters:
src- the source EnumSet- Returns:
- a comma-delimited string of enum values
-