类 DefaultDataFieldMaxValueIncrementerFactory
- java.lang.Object
- org.springframework.batch.item.database.support.DefaultDataFieldMaxValueIncrementerFactory
- 所有已实现的接口:
DataFieldMaxValueIncrementerFactory
public class DefaultDataFieldMaxValueIncrementerFactory extends java.lang.Object implements DataFieldMaxValueIncrementerFactory
Default implementation of theDataFieldMaxValueIncrementerFactory
interface. Valid database types are given by theDatabaseType
enum. Note: For MySql databases, theMySQLMaxValueIncrementer.setUseNewConnection(boolean)
will be set to true.- 作者:
- Lucas Ward, Michael Minella
- 另请参阅:
DatabaseType
构造器概要
构造器 构造器 说明 DefaultDataFieldMaxValueIncrementerFactory(javax.sql.DataSource dataSource)
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 org.springframework.jdbc.support.incrementer.DataFieldMaxValueIncrementer
getIncrementer(java.lang.String incrementerType, java.lang.String incrementerName)
Return theDataFieldMaxValueIncrementer
for the provided database type.java.lang.String[]
getSupportedIncrementerTypes()
Returns the list of supported database incrementer typesboolean
isSupportedIncrementerType(java.lang.String incrementerType)
Returns boolean indicated whether or not the provided string is supported by this factory.void
setIncrementerColumnName(java.lang.String incrementerColumnName)
- * Public setter for the column name (defaults to "ID") in the incrementer. - * Only used by some platforms (Derby, HSQL, MySQL, SQL Server and Sybase), - * and should be fine for use with Spring Batch meta data as long as the default batch schema hasn't been changed.
构造器详细资料
DefaultDataFieldMaxValueIncrementerFactory
public DefaultDataFieldMaxValueIncrementerFactory(javax.sql.DataSource dataSource)
方法详细资料
setIncrementerColumnName
public void setIncrementerColumnName(java.lang.String incrementerColumnName)
- * Public setter for the column name (defaults to "ID") in the incrementer. - * Only used by some platforms (Derby, HSQL, MySQL, SQL Server and Sybase), - * and should be fine for use with Spring Batch meta data as long as the default batch schema hasn't been changed.- 参数:
incrementerColumnName
- the primary key column name to set
getIncrementer
public org.springframework.jdbc.support.incrementer.DataFieldMaxValueIncrementer getIncrementer(java.lang.String incrementerType, java.lang.String incrementerName)
从接口复制的说明:DataFieldMaxValueIncrementerFactory
Return theDataFieldMaxValueIncrementer
for the provided database type.- 指定者:
getIncrementer
在接口中DataFieldMaxValueIncrementerFactory
- 参数:
incrementerType
- string represented database typeincrementerName
- incrementer name to create. In many cases this may be the sequence name- 返回:
- incrementer
isSupportedIncrementerType
public boolean isSupportedIncrementerType(java.lang.String incrementerType)
从接口复制的说明:DataFieldMaxValueIncrementerFactory
Returns boolean indicated whether or not the provided string is supported by this factory.- 指定者:
isSupportedIncrementerType
在接口中DataFieldMaxValueIncrementerFactory
- 参数:
incrementerType
-String
containing the database type.- 返回:
- true if the incrementerType is supported by this database type. Else false is returned.
getSupportedIncrementerTypes
public java.lang.String[] getSupportedIncrementerTypes()
从接口复制的说明:DataFieldMaxValueIncrementerFactory
Returns the list of supported database incrementer types- 指定者:
getSupportedIncrementerTypes
在接口中DataFieldMaxValueIncrementerFactory
- 返回:
- an array of
String
s containing the supported incrementer types.