Package org.apache.cayenne.dba.mysql
Class MySQLPkGenerator
java.lang.Object
org.apache.cayenne.dba.JdbcPkGenerator
org.apache.cayenne.dba.mysql.MySQLPkGenerator
- All Implemented Interfaces:
PkGenerator
-
Field Summary
Fields inherited from class org.apache.cayenne.dba.JdbcPkGenerator
adapter, DEFAULT_PK_CACHE_SIZE, pkCache, pkCacheSize, pkStartValue
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
protected long
getLongPrimaryKey
(Statement statement, String entityName) protected long
longPkFromDatabase
(DataNode node, DbEntity entity) Overrides superclass's implementation to perform locking of the primary key lookup table.protected String
protected SQLException
processSQLException
(SQLException exception, SQLException parent) Appends a new SQLException to the chain.Methods inherited from class org.apache.cayenne.dba.JdbcPkGenerator
autoPkTableExists, createAutoPk, createAutoPkStatements, dropAutoPk, dropAutoPkStatements, generatePk, getAdapter, getPkCacheSize, pkCreateString, pkDeleteString, pkSelectString, pkUpdateString, reset, runUpdate, setAdapter, setPkCacheSize
-
Constructor Details
-
MySQLPkGenerator
public MySQLPkGenerator()Used by DI- Since:
- 4.1
-
-
Method Details
-
longPkFromDatabase
Overrides superclass's implementation to perform locking of the primary key lookup table.- Overrides:
longPkFromDatabase
in classJdbcPkGenerator
- Throws:
Exception
- Since:
- 3.0
-
processSQLException
Appends a new SQLException to the chain. If parent is null, uses the exception as the chain root. -
dropAutoPkString
- Overrides:
dropAutoPkString
in classJdbcPkGenerator
-
pkTableCreateString
- Overrides:
pkTableCreateString
in classJdbcPkGenerator
-
getLongPrimaryKey
- Throws:
SQLException
- Since:
- 3.0
-