public enum CosmosLoadBalancingPolicyOption extends Enum<CosmosLoadBalancingPolicyOption> implements CosmosDriverOption
| Enum Constant and Description |
|---|
MULTI_REGION_WRITES |
PREFERRED_REGIONS |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
getDefaultValue(Class<T> type)
Returns the default value of this
Cosmos driver option. |
String |
getName()
Returns the name this
Cosmos driver option. |
String |
getPath() |
<T> T |
getValue(com.datastax.oss.driver.api.core.config.DriverExecutionProfile profile,
Class<T> type)
Gets the value for this
Cosmos driver option from the given driver execution profile. |
<T> T |
parse(String value,
Class<T> type)
Parses a value for this
Cosmos driver option. |
static CosmosLoadBalancingPolicyOption |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static CosmosLoadBalancingPolicyOption[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final CosmosLoadBalancingPolicyOption MULTI_REGION_WRITES
public static final CosmosLoadBalancingPolicyOption PREFERRED_REGIONS
public static CosmosLoadBalancingPolicyOption[] values()
for (CosmosLoadBalancingPolicyOption c : CosmosLoadBalancingPolicyOption.values()) System.out.println(c);
public static CosmosLoadBalancingPolicyOption valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is null@NonNull
public <T> T getDefaultValue(@NonNull
Class<T> type)
CosmosDriverOptionCosmos driver option.getDefaultValue in interface CosmosDriverOptionT - The class of values for this Cosmos driver option.type - The class of values for this Cosmos driver option.Cosmos driver option.@NonNull public String getName()
CosmosDriverOptionCosmos driver option.getName in interface CosmosDriverOptionCosmos driver option.@NonNull public String getPath()
getPath in interface com.datastax.oss.driver.api.core.config.DriverOption@NonNull
public <T> T getValue(@NonNull
com.datastax.oss.driver.api.core.config.DriverExecutionProfile profile,
@NonNull
Class<T> type)
CosmosDriverOptionCosmos driver option from the given driver execution profile.getValue in interface CosmosDriverOptionT - The class of values for this Cosmos driver option.profile - A driver execution profile from which to get the value.type - The class of values for this Cosmos driver option.Cosmos driver option.@NonNull
public <T> T parse(@Nullable
String value,
@NonNull
Class<T> type)
CosmosDriverOptionCosmos driver option.parse in interface CosmosDriverOptionT - The class of values for this Cosmos driver option.value - A string value to parse.type - The class of values for this Cosmos driver option.Cosmos driver option.Copyright © 2021. All rights reserved.