Interface AttributeCompressionStrategy
- All Superinterfaces:
BlobStrategy
Responsible for performing a specialised JSON compression based on the
attribute name being stored in the JSON.
The compression is a somewhat simple reduction of each Attribute Name
to its initials. This works because we know the fields within the
InternalSession.
This approach is however brittle and only recommended if it will make
the required difference in performance.
-
Field Summary
Fields -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic Collection<Field>Examines the class using reflection for all declared fields which are suitable for serialisation.static StringgetInitials(String name) Generate the initials from the given name.Methods inherited from interface org.forgerock.am.cts.utils.blob.BlobStrategy
perform, reverse
-
Field Details
-
ATTRIBUTE_COMPRESSIBLE
- See Also:
-
-
Method Details
-
getInitials
Generate the initials from the given name. Note: This function is intended to operate against Java field name syntax. As such it simply picks out the first character and all subsequent upper case characters from the String.- Parameters:
name- Non null string that follows Java field name syntax.- Returns:
- The initials of the field.
-
getAllValidFields
Examines the class using reflection for all declared fields which are suitable for serialisation.- Parameters:
c- Non null class to examine.- Returns:
- A non null but possibly empty collection of Fields.
-