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.connection |
Contains classes that manage connecting to MongoDB servers.
|
com.mongodb.operation |
The core of the MongoDB driver works via operations, using the command pattern.
|
Modifier and Type | Method and Description |
---|---|
static WriteConcernResult |
WriteConcernResult.acknowledged(int count,
boolean isUpdateOfExisting,
BsonValue upsertedId)
Create an acknowledged WriteConcernResult
|
WriteConcernResult |
WriteConcernException.getWriteConcernResult()
Gets the write result.
|
WriteConcernResult |
MongoWriteConcernException.getWriteResult()
Gets the write result.
|
static WriteConcernResult |
WriteConcernResult.unacknowledged()
Create an unacknowledged WriteConcernResult
|
Constructor and Description |
---|
DuplicateKeyException(BsonDocument response,
ServerAddress address,
WriteConcernResult writeConcernResult)
Construct an instance.
|
MongoWriteConcernException(WriteConcernError writeConcernError,
WriteConcernResult writeConcernResult,
ServerAddress serverAddress)
Construct an instance.
|
WriteConcernException(BsonDocument response,
ServerAddress address,
WriteConcernResult writeConcernResult)
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
WriteConcernResult |
Connection.delete(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<DeleteRequest> deletes)
Delete the documents using the delete wire protocol and apply the write concern.
|
WriteConcernResult |
Connection.insert(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<InsertRequest> inserts)
Insert the documents using the insert wire protocol and apply the write concern.
|
WriteConcernResult |
Connection.update(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<UpdateRequest> updates)
Update the documents using the update wire protocol and apply the write concern.
|
Modifier and Type | Method and Description |
---|---|
void |
AsyncConnection.deleteAsync(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<DeleteRequest> deletes,
SingleResultCallback<WriteConcernResult> callback)
Delete the documents using the delete wire protocol and apply the write concern asynchronously.
|
void |
AsyncConnection.insertAsync(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<InsertRequest> inserts,
SingleResultCallback<WriteConcernResult> callback)
Insert the documents using the insert wire protocol and apply the write concern asynchronously.
|
void |
AsyncConnection.updateAsync(MongoNamespace namespace,
boolean ordered,
WriteConcern writeConcern,
List<UpdateRequest> updates,
SingleResultCallback<WriteConcernResult> callback)
Update the documents using the update wire protocol and apply the write concern asynchronously.
|
Modifier and Type | Method and Description |
---|---|
WriteConcernResult |
BaseWriteOperation.execute(WriteBinding binding) |
protected abstract WriteConcernResult |
BaseWriteOperation.executeProtocol(Connection connection)
Executes the write protocol
|
protected WriteConcernResult |
UpdateOperation.executeProtocol(Connection connection) |
protected WriteConcernResult |
DeleteOperation.executeProtocol(Connection connection) |
protected WriteConcernResult |
InsertOperation.executeProtocol(Connection connection) |
Modifier and Type | Method and Description |
---|---|
void |
BaseWriteOperation.executeAsync(AsyncWriteBinding binding,
SingleResultCallback<WriteConcernResult> callback) |
protected abstract void |
BaseWriteOperation.executeProtocolAsync(AsyncConnection connection,
SingleResultCallback<WriteConcernResult> callback)
Asynchronously executes the write protocol
|
protected void |
UpdateOperation.executeProtocolAsync(AsyncConnection connection,
SingleResultCallback<WriteConcernResult> callback) |
protected void |
DeleteOperation.executeProtocolAsync(AsyncConnection connection,
SingleResultCallback<WriteConcernResult> callback) |
protected void |
InsertOperation.executeProtocolAsync(AsyncConnection connection,
SingleResultCallback<WriteConcernResult> callback) |
Copyright © 2016. All Rights Reserved.