protected boolean shouldSortPropertiesAlphabetically(Class<?> declaringType) {
        return AnnotationHelper.resolveAnnotation(declaringType, JsonPropertyOrder.class, JacksonModule.NESTED_ANNOTATION_CHECK)
                .map(JsonPropertyOrder::alphabetic)
                .orElse(this.sortAlphabeticallyIfNotAnnotated);
    }
Determine whether the given type's properties that are not specifically mentioned in a {@link JsonPropertyOrder} annotation should be sorted
alphabetically, based on {@link JsonPropertyOrder#alphabetic()}. If no such annotation is present, the value given in the
{@link #JsonPropertySorter(boolean)} constructor.

@param declaringType type for which the properties' default sorting should be determined
@return whether properties that are not specifically mentioned in a {@link JsonPropertyOrder} annotation should be sorted alphabetically
jsonschema-module-jackson/src/main/java/com/github/victools/jsonschema/module/jackson/JsonPropertySorter.java