class PointerLocationEvaluator implements Function<JsonPointer, PointerLocation> {

    @Override
    public PointerLocation apply(final JsonPointer evaluationPointer) {
        checkNotNull(evaluationPointer, "pointer to be evaluated");

        PointerLocation result = PointerLocation.DIFFERENT;
        if (isOnReferencePointer(evaluationPointer)) {
            final int evaluationPointerLevelCount = evaluationPointer.getLevelCount();
            final int referencePointerLevelCount = referencePointer.getLevelCount();
            if (evaluationPointerLevelCount < referencePointerLevelCount) {
                result = PointerLocation.ABOVE;
            } else if (evaluationPointerLevelCount > referencePointerLevelCount) {
                result = PointerLocation.BELOW;
            } else {
                result = PointerLocation.SAME;
            }
        }
        return result;
    }

      PointerLocationEvaluator(final JsonPointer referencePointer);

}