private int nullCompare(Object first, Object second) {
        if (first == second) {
            return 0;
        }
        if (first == null) {
            return -1;
        }
        if (second == null) {
            return 1;
        }
        return NON_NULLS;
    }
Partially compares the two given objects for order, handling null as
necessary.

@return a -1 if the first object is null but not the second, 0 if both
        objects are identical, 1 if the second object is null but not the
        first. Otherwise, {@link #NON_NULLS} is returned which means both
        objects are non-null but not identical.
aws-java-sdk-cloudwatchmetrics/src/main/java/com/amazonaws/metrics/internal/cloudwatch/DimensionComparator.java