code: public void endObject() throws IOException {
      int p = peeked;
      if (p == PEEKED_NONE) {
        p = doPeek();
      }
      if (p == PEEKED_END_OBJECT) {
        stackSize--;
        pathNames[stackSize] = null; // Free the last path name so that it can be garbage collected!
        pathIndices[stackSize - 1]++;
        peeked = PEEKED_NONE;
      } else {
        throw new IllegalStateException("Expected END_OBJECT but was " + peek()
            + " at line " + getLineNumber() + " column " + getColumnNumber() + " path " + getPath());
      }
    }
docs: Consumes the next token from the JSON stream and asserts that it is the
  end of the current object.