public class CountOptions
extends java.lang.Object
| Constructor and Description |
|---|
CountOptions() |
| Modifier and Type | Method and Description |
|---|---|
CountOptions |
collation(Collation collation)
Sets the collation options
|
Collation |
getCollation()
Returns the collation options
|
Bson |
getHint()
Gets the hint to apply.
|
java.lang.String |
getHintString()
Gets the hint string to apply.
|
int |
getLimit()
Gets the limit to apply.
|
long |
getMaxTime(java.util.concurrent.TimeUnit timeUnit)
Gets the maximum execution time on the server for this operation.
|
int |
getSkip()
Gets the number of documents to skip.
|
CountOptions |
hint(Bson hint)
Sets the hint to apply.
|
CountOptions |
hintString(java.lang.String hint)
Sets the hint to apply.
|
CountOptions |
limit(int limit)
Sets the limit to apply.
|
CountOptions |
maxTime(long maxTime,
java.util.concurrent.TimeUnit timeUnit)
Sets the maximum execution time on the server for this operation.
|
CountOptions |
skip(int skip)
Sets the number of documents to skip.
|
java.lang.String |
toString() |
@Nullable public Bson getHint()
@Nullable public java.lang.String getHintString()
public CountOptions hint(@Nullable Bson hint)
hint - a document describing the index which should be used for this operation.public CountOptions hintString(@Nullable java.lang.String hint)
Note: If hint(Bson) is set that will be used instead of any hint string.
hint - the name of the index which should be used for the operationpublic int getLimit()
public CountOptions limit(int limit)
limit - the limitpublic int getSkip()
public CountOptions skip(int skip)
skip - the number of documents to skippublic long getMaxTime(java.util.concurrent.TimeUnit timeUnit)
timeUnit - the time unit to return the result inpublic CountOptions maxTime(long maxTime, java.util.concurrent.TimeUnit timeUnit)
maxTime - the max timetimeUnit - the time unit, which may not be null@Nullable public Collation getCollation()
public CountOptions collation(@Nullable Collation collation)
A null value represents the server default.
collation - the collation options to usepublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2010 - 2023 Adobe. All Rights Reserved