public class WriteConcernException extends MongoException
MongoException.CursorNotFound, MongoException.DuplicateKey, MongoException.Network
Constructor and Description |
---|
WriteConcernException(CommandResult commandResult)
Deprecated.
for internal use only, this constructor will be removed in the next major release
|
Modifier and Type | Method and Description |
---|---|
CommandResult |
getCommandResult()
Deprecated.
|
String |
getErrorMessage()
Gets the error message associated with the write failure.
|
ServerAddress |
getServerAddress()
Gets the address of the server that the write executed on.
|
getCode
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
@Deprecated public WriteConcernException(CommandResult commandResult)
commandResult
- the command resultpublic ServerAddress getServerAddress()
public String getErrorMessage()
@Deprecated public CommandResult getCommandResult()