Package | Description |
---|---|
com.mongodb |
This package is the main entry point to the MongoDB Java Driver, and it contains the classes for the existing API from 2.x versions.
|
com.mongodb.bulk |
Contains classes for representing the result of a bulk write operation.
|
com.mongodb.client.gridfs |
This package contains the new GridFS implementation
|
com.mongodb.client.gridfs.model |
This package contains models for use with GridFS
|
com.mongodb.client.result |
This package contains classes representing operation results
|
com.mongodb.operation |
The core of the MongoDB driver works via operations, using the command pattern.
|
org.bson |
This package contains bson classes required for the driver
|
org.bson.codecs |
This package contains all the default BSON codecs.
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
DBObjectCodec.getDocumentId(DBObject document) |
abstract BsonValue |
WriteConcernResult.getUpsertedId()
Returns the value of _id if this write resulted in an upsert.
|
Modifier and Type | Method and Description |
---|---|
static WriteConcernResult |
WriteConcernResult.acknowledged(int count,
boolean isUpdateOfExisting,
BsonValue upsertedId)
Create an acknowledged WriteConcernResult
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
BulkWriteUpsert.getId()
Gets the id of the upserted item.
|
Constructor and Description |
---|
BulkWriteUpsert(int index,
BsonValue id)
Construct an instance.
|
Modifier and Type | Method and Description |
---|---|
void |
GridFSBucket.downloadToStream(BsonValue id,
OutputStream destination)
Deprecated.
using custom id values for with GridFS is no longer supported
|
GridFSDownloadStream |
GridFSBucket.openDownloadStream(BsonValue id)
Deprecated.
using custom id values for with GridFS is no longer supported
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
GridFSFile.getId()
The
BsonValue id for this file. |
Constructor and Description |
---|
GridFSFile(BsonValue id,
String filename,
long length,
int chunkSize,
Date uploadDate,
String md5,
Document metadata)
Creates a new GridFSFile
|
GridFSFile(BsonValue id,
String filename,
long length,
int chunkSize,
Date uploadDate,
String md5,
Document metadata,
Document extraElements)
Creates a legacy implementation of the GridFSFile
|
Modifier and Type | Method and Description |
---|---|
abstract BsonValue |
UpdateResult.getUpsertedId()
If the replace resulted in an inserted document, gets the _id of the inserted document, otherwise null.
|
Modifier and Type | Method and Description |
---|---|
static UpdateResult |
UpdateResult.acknowledged(long matchedCount,
Long modifiedCount,
BsonValue upsertedId)
Create an acknowledged UpdateResult
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
CountOperation.getHint()
Gets the hint to apply.
|
Modifier and Type | Method and Description |
---|---|
CountOperation |
CountOperation.hint(BsonValue hint)
Sets the hint to apply.
|
Modifier and Type | Class and Description |
---|---|
class |
BsonArray
A type-safe representation of the BSON array type.
|
class |
BsonBinary
A representation of the BSON Binary type.
|
class |
BsonBoolean
A representation of the BSON Boolean type.
|
class |
BsonDateTime
A representation of the BSON DateTime type.
|
class |
BsonDbPointer
Holder for a BSON type DBPointer(0x0c).
|
class |
BsonDocument
A type-safe container for a BSON document.
|
class |
BsonDocumentWrapper<T>
A
BsonDocument that begins its life as a document of any type and an Encoder for that document, which lets an instance of
any class with an Encoder be treated as a BsonDocument. |
class |
BsonDouble
A representation of the BSON Double type.
|
class |
BsonInt32
A representation of the BSON Int32 type.
|
class |
BsonInt64
A representation of the BSON Int64 type.
|
class |
BsonJavaScript
For using the JavaScript Code type.
|
class |
BsonJavaScriptWithScope
A representation of the JavaScript Code with Scope BSON type.
|
class |
BsonMaxKey
Represent the maximum key value regardless of the key's type
|
class |
BsonMinKey
Represent the minimum key value regardless of the key's type
|
class |
BsonNull
A representation of the BSON Null type.
|
class |
BsonNumber
Base class for the three numeric BSON types.
|
class |
BsonObjectId
A representation of the BSON ObjectId type.
|
class |
BsonRegularExpression
A holder class for a BSON regular expression, so that we can delay compiling into a Pattern until necessary.
|
class |
BsonString
A representation of the BSON String type.
|
class |
BsonSymbol
Class to hold a BSON symbol object, which is an interned string in Ruby
|
class |
BsonTimestamp
A value representing the BSON timestamp type.
|
class |
BsonUndefined
Represents the value associated with the BSON Undefined type.
|
class |
RawBsonDocument
An immutable BSON document that is represented using only the raw bytes.
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
BsonArray.get(int index) |
BsonValue |
BsonDocument.get(Object key) |
BsonValue |
RawBsonDocument.get(Object key) |
BsonValue |
BsonDocumentWrapper.get(Object key) |
BsonValue |
BsonDocument.get(Object key,
BsonValue defaultValue)
If the document does not contain the given key, return the given default value.
|
BsonValue |
BsonDocumentReader.Context.getNextValue() |
BsonValue |
BsonElement.getValue()
Gets the value of this element.
|
BsonValue |
BsonDocument.put(String key,
BsonValue value) |
BsonValue |
RawBsonDocument.put(String key,
BsonValue value) |
BsonValue |
BsonDocumentWrapper.put(String key,
BsonValue value) |
BsonValue |
BsonArray.remove(int index) |
BsonValue |
BsonDocument.remove(Object key) |
BsonValue |
RawBsonDocument.remove(Object key) |
BsonValue |
BsonDocumentWrapper.remove(Object key) |
BsonValue |
BsonArray.set(int index,
BsonValue element) |
Modifier and Type | Method and Description |
---|---|
Set<Map.Entry<String,BsonValue>> |
BsonDocument.entrySet() |
Set<Map.Entry<String,BsonValue>> |
RawBsonDocument.entrySet() |
Set<Map.Entry<String,BsonValue>> |
BsonDocumentWrapper.entrySet() |
Map.Entry<String,BsonValue> |
BsonDocumentReader.Context.getNextElement() |
List<BsonValue> |
BsonArray.getValues()
Gets the values in this array as a list of
BsonValue objects. |
Iterator<BsonValue> |
BsonArray.iterator() |
ListIterator<BsonValue> |
BsonArray.listIterator() |
ListIterator<BsonValue> |
BsonArray.listIterator(int index) |
List<BsonValue> |
BsonArray.subList(int fromIndex,
int toIndex) |
Collection<BsonValue> |
BsonDocument.values() |
Collection<BsonValue> |
RawBsonDocument.values() |
Collection<BsonValue> |
BsonDocumentWrapper.values() |
Modifier and Type | Method and Description |
---|---|
boolean |
BsonArray.add(BsonValue bsonValue) |
void |
BsonArray.add(int index,
BsonValue element) |
BsonDocument |
BsonDocument.append(String key,
BsonValue value)
Put the given key and value into this document, and return the document.
|
BsonDocument |
RawBsonDocument.append(String key,
BsonValue value) |
BsonValue |
BsonDocument.get(Object key,
BsonValue defaultValue)
If the document does not contain the given key, return the given default value.
|
BsonValue |
BsonDocument.put(String key,
BsonValue value) |
BsonValue |
RawBsonDocument.put(String key,
BsonValue value) |
BsonValue |
BsonDocumentWrapper.put(String key,
BsonValue value) |
BsonValue |
BsonArray.set(int index,
BsonValue element) |
Modifier and Type | Method and Description |
---|---|
boolean |
BsonArray.addAll(Collection<? extends BsonValue> c) |
boolean |
BsonArray.addAll(int index,
Collection<? extends BsonValue> c) |
void |
BsonDocument.putAll(Map<? extends String,? extends BsonValue> m) |
void |
RawBsonDocument.putAll(Map<? extends String,? extends BsonValue> m) |
void |
BsonDocumentWrapper.putAll(Map<? extends String,? extends BsonValue> m) |
Constructor and Description |
---|
BsonDocument(String key,
BsonValue value)
Construct a new instance with a single key value pair
|
BsonElement(String name,
BsonValue value)
Construct a new instance with the given key and value
|
Constructor and Description |
---|
BsonArray(List<? extends BsonValue> values)
Construct an instance with the given list of values.
|
Modifier and Type | Method and Description |
---|---|
BsonValue |
BsonValueCodec.decode(BsonReader reader,
DecoderContext decoderContext) |
BsonValue |
BsonDocumentCodec.getDocumentId(BsonDocument document) |
BsonValue |
DocumentCodec.getDocumentId(Document document) |
BsonValue |
CollectibleCodec.getDocumentId(T document)
Gets the _id of the given document if it contains one, otherwise throws
IllegalArgumentException . |
protected BsonValue |
BsonDocumentCodec.readValue(BsonReader reader,
DecoderContext decoderContext)
This method may be overridden to change the behavior of reading the current value from the given
BsonReader . |
protected BsonValue |
BsonArrayCodec.readValue(BsonReader reader,
DecoderContext decoderContext)
This method may be overridden to change the behavior of reading the current value from the given
BsonReader . |
Modifier and Type | Method and Description |
---|---|
static Class<? extends BsonValue> |
BsonValueCodecProvider.getClassForBsonType(BsonType bsonType)
Get the
BsonValue subclass associated with the given BsonType . |
Class<BsonValue> |
BsonValueCodec.getEncoderClass() |
Modifier and Type | Method and Description |
---|---|
void |
BsonValueCodec.encode(BsonWriter writer,
BsonValue value,
EncoderContext encoderContext) |
Copyright © 2016. All Rights Reserved.