private JsonToken readToken() throws JsonParseException {
    switch (type()) {
      case END_OF_DOCUMENT:
        reader.readEndDocument();
        return JsonToken.END_OBJECT;
      case DOCUMENT:
        reader.readStartDocument();
        return JsonToken.START_OBJECT;
      case ARRAY:
        reader.readStartArray();
        return JsonToken.START_ARRAY;
      case BOOLEAN:
        final boolean value  = reader.readBoolean();
        context.setValue(value);
        return value ? JsonToken.VALUE_TRUE : JsonToken.VALUE_FALSE;
      case DATE_TIME:
      case TIMESTAMP:
        return JsonToken.VALUE_EMBEDDED_OBJECT;
      case NULL:
        reader.readNull();
        context.setValue(null);
        return JsonToken.VALUE_NULL;
      case SYMBOL:
      case STRING:
        return JsonToken.VALUE_STRING;
      case INT32:
      case INT64:
        return JsonToken.VALUE_NUMBER_INT;
      case DECIMAL128:
      case DOUBLE:
        return JsonToken.VALUE_NUMBER_FLOAT;
      case UNDEFINED:
        reader.readUndefined();
        context.setValue(null);
        return JsonToken.VALUE_NULL;
      case OBJECT_ID:
      case BINARY:
      case REGULAR_EXPRESSION:
      default:
        return JsonToken.VALUE_EMBEDDED_OBJECT;
    }
  }
Read next token in the stream
criteria/mongo/src/org/immutables/criteria/mongo/bson4jackson/BsonParser.java