Class IdPAttributePrincipalSerializer

    • Constructor Detail

      • IdPAttributePrincipalSerializer

        public IdPAttributePrincipalSerializer()
        Constructor.
    • Method Detail

      • supports

        public boolean supports​(@Nonnull
                                Principal principal)
      • serializeValue

        @Nonnull
        protected javax.json.JsonObject serializeValue​(@Nonnull
                                                       IdPAttributeValue value)
        Serialize an attribute value and produce a JsonObject.

        Override this method to support additional value types.

        Parameters:
        value - the attribute value to serialize
        Returns:
        the object
      • deserializeValue

        @Nullable
        protected IdPAttributeValue deserializeValue​(@Nonnull
                                                     javax.json.JsonObject object)
        Deserialize an attribute value from a JsonObject.

        Override this method to support additional value types.

        Parameters:
        object - object to deserialize
        Returns:
        the attribute value, or null
      • getJsonObjectBuilder

        @Nonnull
        private javax.json.JsonObjectBuilder getJsonObjectBuilder()
        Get a JsonObjectBuilder in a thread-safe manner.
        Returns:
        an object builder
      • getJsonArrayBuilder

        @Nonnull
        private javax.json.JsonArrayBuilder getJsonArrayBuilder()
        Get a JsonArrayBuilder in a thread-safe manner.
        Returns:
        an array builder