Uses of Interface java.sql.ShardingKey (Java SE 25 & JDK 25)
Description: use: module: java.sql, package: java.sql, interface: ShardingKey

# Uses of Interface
java.sql.ShardingKey

Packages that use ShardingKey
Package
Description
java.sql
Provides the API for accessing and processing data stored in a data source (usually a relational database) using the Java programming language.
javax.sql
Provides the API for server side data source access and processing from the Java programming language.

- ## Uses of ShardingKey in java.sql

  Methods in java.sql that return ShardingKey
  Modifier and Type
  Method
  Description
  `ShardingKey`
  ShardingKeyBuilder.`build()`
  Returns an instance of the object defined by this builder.
  Methods in java.sql with parameters of type ShardingKey
  Modifier and Type
  Method
  Description
  `default void`
  Connection.`setShardingKey(ShardingKey shardingKey)`
  Specifies a shardingKey to use with this Connection
  `default void`
  Connection.`setShardingKey(ShardingKey shardingKey, ShardingKey superShardingKey)`
  Specifies a shardingKey and superShardingKey to use with this Connection
  `default boolean`
  Connection.`setShardingKeyIfValid(ShardingKey shardingKey, int timeout)`
  Sets and validates the sharding key for this connection.
  `default boolean`
  Connection.`setShardingKeyIfValid(ShardingKey shardingKey, ShardingKey superShardingKey, int timeout)`
  Sets and validates the sharding keys for this connection.
  `ConnectionBuilder`
  ConnectionBuilder.`shardingKey(ShardingKey shardingKey)`
  Specifies a `shardingKey` to be used when creating a connection
  `ConnectionBuilder`
  ConnectionBuilder.`superShardingKey(ShardingKey superShardingKey)`
  Specifies a `superShardingKey` to be used when creating a connection

- ## Uses of ShardingKey in javax.sql

  Methods in javax.sql with parameters of type ShardingKey
  Modifier and Type
  Method
  Description
  `PooledConnectionBuilder`
  PooledConnectionBuilder.`shardingKey(ShardingKey shardingKey)`
  Specifies a `shardingKey` to be used when creating a connection
  `XAConnectionBuilder`
  XAConnectionBuilder.`shardingKey(ShardingKey shardingKey)`
  Specifies a `shardingKey` to be used when creating a connection
  `PooledConnectionBuilder`
  PooledConnectionBuilder.`superShardingKey(ShardingKey superShardingKey)`
  Specifies a `superShardingKey` to be used when creating a connection
  `XAConnectionBuilder`
  XAConnectionBuilder.`superShardingKey(ShardingKey superShardingKey)`
  Specifies a `superShardingKey` to be used when creating a connection