@Override
    public int compareTo(@Nonnull final AttributeDefinition definition) {
        return Comparator.comparing(AttributeDefinition::getKey).compare(this, definition);
    }
This is {@link DefaultAttributeDefinition}.

@author Misagh Moayyed
@author Travis Schmidt
@since 6.2.0
core/cas-server-core-authentication-api/src/main/java/org/apereo/cas/authentication/attribute/DefaultAttributeDefinition.java