Record Class SqlBatchSupport.JdbcBatchMetadata
java.lang.Object
java.lang.Record
io.micronaut.data.runtime.operations.internal.sql.SqlBatchSupport.JdbcBatchMetadata
- Record Components:
databaseProductName- The database product namedatabaseProductVersion- The database product versiondriverName- The JDBC driver namesupportsBatchUpdates- Whether the driver reports batch-update supportsupportsGetGeneratedKeys- Whether the driver reports generated-key support
- Enclosing class:
SqlBatchSupport
public static record SqlBatchSupport.JdbcBatchMetadata(@Nullable String databaseProductName, @Nullable String databaseProductVersion, @Nullable String driverName, @Nullable Boolean supportsBatchUpdates, @Nullable Boolean supportsGetGeneratedKeys)
extends Record
The JDBC metadata used to resolve batch insert capabilities. Any value can be
null
when the metadata could not be read.- Since:
- 5.2.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final SqlBatchSupport.JdbcBatchMetadataThe metadata used when the JDBC metadata could not be read. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable StringReturns the value of thedatabaseProductNamerecord component.@Nullable StringReturns the value of thedatabaseProductVersionrecord component.@Nullable StringReturns the value of thedriverNamerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanbooleanisMySql()@Nullable BooleanReturns the value of thesupportsBatchUpdatesrecord component.@Nullable BooleanReturns the value of thesupportsGetGeneratedKeysrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
UNKNOWN
The metadata used when the JDBC metadata could not be read.
-
-
Constructor Details
-
JdbcBatchMetadata
public JdbcBatchMetadata(@Nullable String databaseProductName, @Nullable String databaseProductVersion, @Nullable String driverName, @Nullable Boolean supportsBatchUpdates, @Nullable Boolean supportsGetGeneratedKeys) Creates an instance of aJdbcBatchMetadatarecord class.- Parameters:
databaseProductName- the value for thedatabaseProductNamerecord componentdatabaseProductVersion- the value for thedatabaseProductVersionrecord componentdriverName- the value for thedriverNamerecord componentsupportsBatchUpdates- the value for thesupportsBatchUpdatesrecord componentsupportsGetGeneratedKeys- the value for thesupportsGetGeneratedKeysrecord component
-
-
Method Details
-
isMariaDb
public boolean isMariaDb()- Returns:
trueif the connection is known to target a MariaDB server
-
isMySql
public boolean isMySql()- Returns:
trueif the connection is known to target a MySQL server
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
databaseProductName
Returns the value of thedatabaseProductNamerecord component.- Returns:
- the value of the
databaseProductNamerecord component
-
databaseProductVersion
Returns the value of thedatabaseProductVersionrecord component.- Returns:
- the value of the
databaseProductVersionrecord component
-
driverName
Returns the value of thedriverNamerecord component.- Returns:
- the value of the
driverNamerecord component
-
supportsBatchUpdates
Returns the value of thesupportsBatchUpdatesrecord component.- Returns:
- the value of the
supportsBatchUpdatesrecord component
-
supportsGetGeneratedKeys
Returns the value of thesupportsGetGeneratedKeysrecord component.- Returns:
- the value of the
supportsGetGeneratedKeysrecord component
-