int nestingOffset(JsonToken token) {
        if (token == null) return 0;
        if (token.isStructStart()) {
            return 1;
        } else if (token.isStructEnd()) {
            return -1;
        } else {
            return 0;
        }
    }
Returns a sequence of remaining tokens in this, or nulls when none remain.
This may fill the token buffer, but not otherwise modify it.
document/src/main/java/com/yahoo/document/json/TokenBuffer.java