Package com.mongodb
Class ReadPreferenceHedgeOptions.Builder
- java.lang.Object
-
- com.mongodb.ReadPreferenceHedgeOptions.Builder
-
- Enclosing class:
- ReadPreferenceHedgeOptions
public static final class ReadPreferenceHedgeOptions.Builder extends Object
The builder for read preference hedge options
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ReadPreferenceHedgeOptions
build()
Build the transaction options instance.ReadPreferenceHedgeOptions.Builder
enabled(boolean enabled)
Sets whether hedged reads are enabled in the server.
-
-
-
Method Detail
-
enabled
public ReadPreferenceHedgeOptions.Builder enabled(boolean enabled)
Sets whether hedged reads are enabled in the server.- Parameters:
enabled
- true if hedged reads are enabled- Returns:
- this
-
build
public ReadPreferenceHedgeOptions build()
Build the transaction options instance.- Returns:
- The
TransactionOptions
-
-