Package com.mongodb.operation
Class UserExistsOperation
- java.lang.Object
-
- com.mongodb.operation.UserExistsOperation
-
- All Implemented Interfaces:
AsyncReadOperation<java.lang.Boolean>
,ReadOperation<java.lang.Boolean>
@Deprecated public class UserExistsOperation extends java.lang.Object implements AsyncReadOperation<java.lang.Boolean>, ReadOperation<java.lang.Boolean>
Deprecated.useCommandWriteOperation
directly or the mongod shell helpers.An operation that determines if a user exists.- Since:
- 3.0
-
-
Constructor Summary
Constructors Constructor Description UserExistsOperation(java.lang.String databaseName, java.lang.String userName)
Deprecated.Construct a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.Boolean
execute(ReadBinding binding)
Deprecated.General execute which can return anything of type Tvoid
executeAsync(AsyncReadBinding binding, SingleResultCallback<java.lang.Boolean> callback)
Deprecated.General execute which can return anything of type Tboolean
getRetryReads()
Deprecated.Gets the value for retryable reads.UserExistsOperation
retryReads(boolean retryReads)
Deprecated.Enables retryable reads if a read fails due to a network error.
-
-
-
Method Detail
-
retryReads
public UserExistsOperation retryReads(boolean retryReads)
Deprecated.Enables retryable reads if a read fails due to a network error.- Parameters:
retryReads
- true if reads should be retried- Returns:
- this
- Since:
- 3.11
-
getRetryReads
public boolean getRetryReads()
Deprecated.Gets the value for retryable reads. The default is true.- Returns:
- the retryable reads value
- Since:
- 3.11
-
execute
public java.lang.Boolean execute(ReadBinding binding)
Deprecated.Description copied from interface:ReadOperation
General execute which can return anything of type T- Specified by:
execute
in interfaceReadOperation<java.lang.Boolean>
- Parameters:
binding
- the binding to execute in the context of- Returns:
- T, the result of the execution
-
executeAsync
public void executeAsync(AsyncReadBinding binding, SingleResultCallback<java.lang.Boolean> callback)
Deprecated.Description copied from interface:AsyncReadOperation
General execute which can return anything of type T- Specified by:
executeAsync
in interfaceAsyncReadOperation<java.lang.Boolean>
- Parameters:
binding
- the binding to execute in the context ofcallback
- the callback to be called when the operation has been executed
-
-