Package com.azure.cosmos
Enum ConnectionMode
- All Implemented Interfaces:
Serializable
,Comparable<ConnectionMode>
,java.lang.constant.Constable
Represents the connection mode to be used by the client in the Azure Cosmos DB database service.
DIRECT and GATEWAY connectivity modes are supported. DIRECT is the default.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic ConnectionMode
Returns the enum constant of this type with the specified name.static ConnectionMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
GATEWAY
Specifies that requests to server resources are made through a gateway proxy using HTTPS.In GATEWAY mode, all requests are made through a gateway proxy.
-
DIRECT
Specifies that requests to server resources are made directly to the data nodes.In DIRECT mode, all requests to server resources within a container, such as items, stored procedures and user-defined functions, etc., are made directly to the data nodes within the target Cosmos DB cluster using either the HTTPS or TCP/SSL transport protocol.
Certain operations on account or database level resources, such as databases, containers and users, etc., are always routed through the gateway using HTTPS.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-