@JsonIgnore
    default Object toAttributeValue(final Object givenValues) {
        return isSingleValue() && givenValues instanceof final Collection values && values.size() == 1
            ? values.iterator().next()
            : givenValues;
    }
To attribute value.

@param givenValues the given values
@return the object
api/cas-server-core-api-services/src/main/java/org/apereo/cas/authentication/attribute/AttributeDefinition.java