Package org.apache.cayenne.dba.sybase
Class SybaseAdapter
java.lang.Object
org.apache.cayenne.dba.JdbcAdapter
org.apache.cayenne.dba.sybase.SybaseAdapter
- All Implemented Interfaces:
DbAdapter
- Direct Known Subclasses:
SQLServerAdapter
DbAdapter implementation for Sybase RDBMS.
-
Field Summary
Fields inherited from class org.apache.cayenne.dba.JdbcAdapter
batchQueryBuilderFactory, caseInsensitiveCollations, ejbqlTranslatorFactory, extendedTypes, logger, quotingStrategy, resourceLocator, supportsBatchUpdates, supportsGeneratedKeys, supportsUniqueConstraints, typesHandler
-
Constructor Summary
ConstructorDescriptionSybaseAdapter
(RuntimeProperties runtimeProperties, List<ExtendedType> defaultExtendedTypes, List<ExtendedType> userExtendedTypes, List<ExtendedTypeFactory> extendedTypeFactories, ResourceLocator resourceLocator, ValueObjectTypeRegistry valueObjectTypeRegistry) -
Method Summary
Modifier and TypeMethodDescriptionvoid
bindParameter
(PreparedStatement statement, ParameterBinding binding) Binds an object value to PreparedStatement's parameter.protected void
Installs appropriate ExtendedTypes as converters for passing values between JDBC and Java layers.protected EJBQLTranslatorFactory
Creates and returns anEJBQLTranslatorFactory
used to generate visitors for EJBQL to SQL translations.protected PkGenerator
Creates and returns a primary key generator.protected QuotingStrategy
void
createTableAppendColumn
(StringBuffer sqlBuffer, DbAttribute column) Overrides super implementation to correctly set up identity columns.Returns word "go".Methods inherited from class org.apache.cayenne.dba.JdbcAdapter
buildAttribute, createFkConstraint, createTable, createTableAppendPKClause, createUniqueConstraint, dropTableStatements, externalTypesForJdbcType, findResource, getAction, getEjbqlTranslatorFactory, getExtendedTypes, getJdbcEventLogger, getPkGenerator, getQuotingStrategy, getSelectTranslator, getSelectTranslator, getSystemCatalogs, getSystemSchemas, getType, initExtendedTypes, setEjbqlTranslatorFactory, setPkGenerator, setSupportsBatchUpdates, setSupportsGeneratedKeys, setSupportsUniqueConstraints, sizeAndPrecision, supportsBatchUpdates, supportsCatalogsOnReverseEngineering, supportsGeneratedKeys, supportsUniqueConstraints, tableTypeForTable, tableTypeForView, typeSupportsLength, unwrap
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.cayenne.dba.DbAdapter
supportsGeneratedKeysForBatchInserts
-
Constructor Details
-
SybaseAdapter
public SybaseAdapter(RuntimeProperties runtimeProperties, List<ExtendedType> defaultExtendedTypes, List<ExtendedType> userExtendedTypes, List<ExtendedTypeFactory> extendedTypeFactories, ResourceLocator resourceLocator, ValueObjectTypeRegistry valueObjectTypeRegistry)
-
-
Method Details
-
createQuotingStrategy
- Overrides:
createQuotingStrategy
in classJdbcAdapter
-
createEJBQLTranslatorFactory
Description copied from class:JdbcAdapter
Creates and returns anEJBQLTranslatorFactory
used to generate visitors for EJBQL to SQL translations. This method should be overriden by subclasses that need to customize EJBQL generation.- Overrides:
createEJBQLTranslatorFactory
in classJdbcAdapter
- Since:
- 3.0
-
getSqlTreeProcessor
- Specified by:
getSqlTreeProcessor
in interfaceDbAdapter
- Overrides:
getSqlTreeProcessor
in classJdbcAdapter
- Returns:
SQLTreeProcessor
that can adjust SQL tree to specific database flavour- Since:
- 4.2
-
getBatchTerminator
Returns word "go".- Specified by:
getBatchTerminator
in interfaceDbAdapter
- Overrides:
getBatchTerminator
in classJdbcAdapter
- Since:
- 1.0.4
-
configureExtendedTypes
Installs appropriate ExtendedTypes as converters for passing values between JDBC and Java layers.- Overrides:
configureExtendedTypes
in classJdbcAdapter
-
createPkGenerator
Creates and returns a primary key generator. Overrides superclass implementation to return an instance of SybasePkGenerator.- Overrides:
createPkGenerator
in classJdbcAdapter
-
bindParameter
Description copied from interface:DbAdapter
Binds an object value to PreparedStatement's parameter.- Specified by:
bindParameter
in interfaceDbAdapter
- Overrides:
bindParameter
in classJdbcAdapter
- Throws:
Exception
-
createTableAppendColumn
Overrides super implementation to correctly set up identity columns.- Specified by:
createTableAppendColumn
in interfaceDbAdapter
- Overrides:
createTableAppendColumn
in classJdbcAdapter
- Parameters:
sqlBuffer
- theStringBuffer
to append the column type tocolumn
- theDbAttribute
defining the column to append type for- Since:
- 1.2, 4.1 moved from SQLServerAdapter to SybaseAdapter as it supports this too
-