|
EclipseLink 1.1.4, build 'v20100812-r7860' API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform org.eclipse.persistence.internal.databaseaccess.DatabasePlatform org.eclipse.persistence.platform.database.DatabasePlatform org.eclipse.persistence.platform.database.PostgreSQLPlatform
public class PostgreSQLPlatform
Purpose: Provides Postgres specific behavior.
Responsibilities:
Field Summary |
---|
Fields inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform |
---|
classTypes, cursorCode, DEFAULT_MAX_BATCH_WRITING_SIZE, DEFAULT_PARAMETERIZED_MAX_BATCH_WRITING_SIZE, fieldTypes, maxBatchWritingSize, pingSQL, shouldBindAllParameters, shouldCacheAllStatements, shouldForceFieldNamesToUpperCase, shouldIgnoreCaseOnFieldComparisons, shouldOptimizeDataConversion, shouldTrimStrings, statementCacheSize, stringBindingSize, structConverters, supportsAutoCommit, transactionIsolation, typeConverters, Types_NCLOB, useRownumFiltering, usesBatchWriting, usesByteArrayBinding, usesJDBCBatchWriting, usesNativeBatchWriting, usesNativeSQL, usesStreamsForBinding, usesStringBinding |
Fields inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform |
---|
conversionManager, dataTypesConvertedFromAClass, dataTypesConvertedToAClass, defaultSequence, platformOperators, sequences, tableQualifier, timestampQuery |
Constructor Summary | |
---|---|
PostgreSQLPlatform()
|
Method Summary | |
---|---|
protected void |
appendBoolean(java.lang.Boolean bool,
java.io.Writer writer)
Appends a Boolean value. |
protected java.util.Hashtable |
buildFieldTypes()
|
ValueReadQuery |
buildSelectQueryForIdentity()
INTERNAL: Returns query used to read back the value generated by Identity. |
ValueReadQuery |
buildSelectQueryForSequenceObject(java.lang.String seqName,
java.lang.Integer size)
INTERNAL: Returns query used to read value generated by sequence object (like Oracle sequence). |
java.io.Writer |
buildSequenceObjectAlterIncrementWriter(java.io.Writer writer,
java.lang.String fullSeqName,
int increment)
INTERNAL: Override this method if the platform supports sequence objects and isAlterSequenceObjectSupported returns true. |
java.io.Writer |
buildSequenceObjectCreationWriter(java.io.Writer writer,
java.lang.String fullSeqName,
int increment,
int start)
INTERNAL: Override this method if the platform supports sequence objects. |
java.io.Writer |
buildSequenceObjectDeletionWriter(java.io.Writer writer,
java.lang.String fullSeqName)
INTERNAL: Override this method if the platform supports sequence objects. |
int |
computeMaxRowsForSQL(int firstResultIndex,
int maxResults)
INTERNAL: Use the JDBC maxResults and firstResultIndex setting to compute a value to use when limiting the results of a query in SQL. |
java.lang.String |
getAssignmentString()
INTERNAL Used for stored function calls. |
protected java.lang.String |
getCreateTempTableSqlBodyForTable(org.eclipse.persistence.internal.helper.DatabaseTable table)
INTERNAL: |
protected java.lang.String |
getCreateTempTableSqlPrefix()
INTERNAL: |
protected java.lang.String |
getCreateTempTableSqlSuffix()
INTERNAL: |
java.lang.String |
getInOutputProcedureToken()
This method is used to print the output parameter token when stored procedures are called |
int |
getMaxFieldNameSize()
INTERNAL: returns the maximum number of characters that can be used in a field name on this platform. |
java.lang.String |
getProcedureBeginString()
INTERNAL: Used for sp calls. |
java.lang.String |
getProcedureCallHeader()
INTERNAL: Used for sp calls. |
java.lang.String |
getProcedureEndString()
INTERNAL: Used for sp calls. |
ValueReadQuery |
getTimestampQuery()
INTERNAL: This method returns the query to select the timestamp from the server for Derby. |
protected void |
initializePlatformOperators()
INTERNAL: Initialize any platform-specific operators |
boolean |
isAlterSequenceObjectSupported()
INTERNAL: Override this method if the platform supports sequence objects and it's possible to alter sequence object's increment in the database. |
boolean |
isPostgreSQL()
INTERNAL: Answers whether platform is Derby |
protected ExpressionOperator |
operatorLocate()
INTERNAL: Override the default locate operator |
void |
printFieldIdentityClause(java.io.Writer writer)
INTERNAL: Append the receiver's field 'identity' constraint clause to a writer |
void |
printFieldTypeSize(java.io.Writer writer,
FieldDefinition field,
org.eclipse.persistence.internal.databaseaccess.FieldTypeDefinition fieldType,
boolean shouldPrintFieldIdentityClause)
|
void |
printFieldUnique(java.io.Writer writer,
boolean shouldPrintFieldIdentityClause)
|
void |
printSQLSelectStatement(org.eclipse.persistence.internal.databaseaccess.DatabaseCall call,
org.eclipse.persistence.internal.expressions.ExpressionSQLPrinter printer,
org.eclipse.persistence.internal.expressions.SQLSelectStatement statement)
|
boolean |
shouldPrintAliasForUpdate()
INTERNAL: Indicates whether locking OF clause should print alias for field. |
boolean |
shouldPrintOutputTokenAtStart()
This is required in the construction of the stored procedures with output parameters |
boolean |
shouldUseJDBCOuterJoinSyntax()
JDBC defines and outer join syntax, many drivers do not support this. |
boolean |
supportsGlobalTempTables()
INTERNAL: |
boolean |
supportsIdentity()
INTERNAL: Indicates whether the platform supports identity. |
boolean |
supportsSequenceObjects()
INTERNAL: Indicates whether the platform supports sequence objects. |
protected ExpressionOperator |
toNumberOperator()
INTERNAL: Postgres to_number has two arguments, as fix format argument. |
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform |
---|
addBatch, addStructConverter, allowsSizeInProcedureArguments, appendByteArray, appendCalendar, appendDate, appendLiteralToCall, appendLiteralToCallWithBinding, appendNumber, appendParameter, appendParameterInternal, appendString, appendTime, appendTimestamp, autoCommit, beginTransaction, buildCallWithReturning, buildClassTypes, buildProcedureCallString, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, canBatchWriteWithOptimisticLocking, canBuildCallWithReturning, commitTransaction, convertToDatabaseType, copyInto, createArray, createArray, createPlatformDefaultSequence, createStruct, createStruct, dontBindUpdateAllQueryUsingTempTables, executeBatch, executeStoredProcedure, getBatchBeginString, getBatchDelimiterString, getBatchEndString, getClassTypes, getConnection, getConstraintDeletionString, getCreateViewString, getCreationInOutputProcedureToken, getCreationOutputProcedureToken, getCursorCode, getCustomModifyValueForCall, getFieldTypeDefinition, getFieldTypes, getFunctionCallHeader, getIdentifierQuoteCharacter, getInputProcedureToken, getJDBCOuterJoinString, getJDBCType, getJDBCType, getJdbcTypeName, getMaxBatchWritingSize, getMaxForeignKeyNameSize, getMaxUniqueKeyNameSize, getNoWaitString, getObjectFromResultSet, getOutputProcedureToken, getPingSQL, getProcedureArgumentSetter, getProcedureArgumentString, getProcedureAsString, getProcedureCallTail, getQualifiedName, getQualifiedSequenceTableName, getRefValue, getRefValue, getSelectForUpdateNoWaitString, getSelectForUpdateOfString, getSelectForUpdateString, getSelectForUpdateWaitString, getSequenceCounterFieldName, getSequenceNameFieldName, getSequencePreallocationSize, getSequenceTableName, getStatementCacheSize, getStoredProcedureParameterPrefix, getStoredProcedureTerminationToken, getStringBindingSize, getStructConverters, getTempTableForTable, getTransactionIsolation, getTypeConverters, isInformixOuterJoin, isLockTimeoutException, isNullAllowedInSelectClause, isXDBDocument, maximumNumericValues, minimumNumericValues, prepareBatchStatement, printFieldNotNullClause, printFieldNullClause, printFieldTypeSize, printFieldUnique, printValuelist, printValuelist, processResultSet, registerOutputParameter, requiresNamedPrimaryKeyConstraints, requiresProcedureBrackets, requiresProcedureCallBrackets, requiresProcedureCallOuputToken, requiresTypeNameToRegisterOutputParameter, rollbackTransaction, setClassTypes, setCursorCode, setFieldTypes, setMaxBatchWritingSize, setParameterValueInDatabaseCall, setPingSQL, setSequenceCounterFieldName, setSequenceNameFieldName, setSequenceTableName, setShouldBindAllParameters, setShouldCacheAllStatements, setShouldForceFieldNamesToUpperCase, setShouldIgnoreCaseOnFieldComparisons, setShouldOptimizeDataConversion, setShouldTrimStrings, setShouldUseRownumFiltering, setStatementCacheSize, setStringBindingSize, setSupportsAutoCommit, setTransactionIsolation, setUsesBatchWriting, setUsesByteArrayBinding, setUsesJDBCBatchWriting, setUsesNativeBatchWriting, setUsesNativeSQL, setUsesStreamsForBinding, setUsesStringBinding, shouldAlwaysUseTempStorageForModifyAll, shouldBindAllParameters, shouldBindLiterals, shouldCacheAllStatements, shouldForceFieldNamesToUpperCase, shouldIgnoreCaseOnFieldComparisons, shouldIgnoreException, shouldNativeSequenceUseTransaction, shouldOptimizeDataConversion, shouldPrintConstraintNameAfter, shouldPrintFieldIdentityClause, shouldPrintInOutputTokenBeforeType, shouldPrintInputTokenAtStart, shouldPrintLockingClauseAfterWhereClause, shouldPrintOuterJoinInWhereClause, shouldPrintOutputTokenBeforeType, shouldPrintStoredProcedureArgumentNameInCall, shouldPrintStoredProcedureVariablesAfterBeginString, shouldTempTableSpecifyPrimaryKeys, shouldTrimStrings, shouldUseCustomModifyForCall, shouldUseRownumFiltering, supportsAutoCommit, supportsForeignKeyConstraints, supportsLocalTempTables, supportsNativeSequenceNumbers, supportsPrimaryKeyConstraint, supportsStoredFunctions, supportsTempTables, supportsUniqueKeyConstraints, usesBatchWriting, usesByteArrayBinding, usesJDBCBatchWriting, usesNativeBatchWriting, usesNativeSQL, usesSequenceTable, usesStreamsForBinding, usesStringBinding, wasFailureCommunicationBased, writeAutoAssignmentSetClause, writeAutoJoinWhereClause, writeCleanUpTempTableSql, writeCreateTempTableSql, writeDeleteFromTargetTableUsingTempTableSql, writeFields, writeFieldsAutoClause, writeFieldsList, writeInsertIntoTableSql, writeJoinWhereClause, writeLOB, writeParameterMarker, writeUpdateOriginalFromTempTableSql |
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform |
---|
addOperator, addSequence, clone, convertObject, createConnectionCustomizer, createSequences, getConversionManager, getDataTypesConvertedFrom, getDataTypesConvertedTo, getDefaultSequence, getDefaultSequenceToWrite, getOperator, getPlatformOperators, getSelectSequenceQuery, getSequence, getSequences, getSequencesToWrite, getTableQualifier, getTimestampFromServer, getUpdateSequenceQuery, hasDefaultSequence, isAccess, isAttunity, isCloudscape, isDB2, isDBase, isDerby, isHSQL, isInformix, isMySQL, isODBC, isOracle, isOracle9, isPointBase, isSQLAnywhere, isSQLServer, isSybase, isTimesTen, isTimesTen7, removeAllSequences, removeSequence, sequencesAfterCloneCleanup, setConversionManager, setDefaultSequence, setSelectSequenceNumberQuery, setSequencePreallocationSize, setSequences, setTableQualifier, setTimestampQuery, setUpdateSequenceQuery, toString, usesPlatformDefaultSequence |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PostgreSQLPlatform()
Method Detail |
---|
protected void appendBoolean(java.lang.Boolean bool, java.io.Writer writer) throws java.io.IOException
appendBoolean
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public int computeMaxRowsForSQL(int firstResultIndex, int maxResults)
computeMaxRowsForSQL
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
readQuery
- firstResultIndex
- maxResults
- MySQLPlatform
protected void initializePlatformOperators()
initializePlatformOperators
in class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
protected ExpressionOperator toNumberOperator()
public ValueReadQuery getTimestampQuery()
getTimestampQuery
in interface org.eclipse.persistence.internal.databaseaccess.Platform
getTimestampQuery
in class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
public java.lang.String getInOutputProcedureToken()
getInOutputProcedureToken
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public boolean shouldPrintOutputTokenAtStart()
shouldPrintOutputTokenAtStart
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public boolean isPostgreSQL()
isPostgreSQL
in interface org.eclipse.persistence.internal.databaseaccess.Platform
isPostgreSQL
in class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
protected java.lang.String getCreateTempTableSqlSuffix()
getCreateTempTableSqlSuffix
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public boolean shouldPrintAliasForUpdate()
shouldPrintAliasForUpdate
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public boolean supportsIdentity()
supportsIdentity
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public ValueReadQuery buildSelectQueryForIdentity()
buildSelectQueryForIdentity
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public boolean supportsSequenceObjects()
supportsSequenceObjects
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public ValueReadQuery buildSelectQueryForSequenceObject(java.lang.String seqName, java.lang.Integer size)
buildSelectQueryForSequenceObject
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
protected java.lang.String getCreateTempTableSqlBodyForTable(org.eclipse.persistence.internal.helper.DatabaseTable table)
getCreateTempTableSqlBodyForTable
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public void printFieldIdentityClause(java.io.Writer writer) throws ValidationException
printFieldIdentityClause
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
ValidationException
protected java.util.Hashtable buildFieldTypes()
buildFieldTypes
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
protected ExpressionOperator operatorLocate()
public boolean supportsGlobalTempTables()
supportsGlobalTempTables
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
protected java.lang.String getCreateTempTableSqlPrefix()
getCreateTempTableSqlPrefix
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public int getMaxFieldNameSize()
getMaxFieldNameSize
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public java.lang.String getProcedureBeginString()
getProcedureBeginString
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public java.lang.String getProcedureEndString()
getProcedureEndString
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public java.lang.String getProcedureCallHeader()
getProcedureCallHeader
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public java.lang.String getAssignmentString()
getAssignmentString
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public void printFieldTypeSize(java.io.Writer writer, FieldDefinition field, org.eclipse.persistence.internal.databaseaccess.FieldTypeDefinition fieldType, boolean shouldPrintFieldIdentityClause) throws java.io.IOException
printFieldTypeSize
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public void printFieldUnique(java.io.Writer writer, boolean shouldPrintFieldIdentityClause) throws java.io.IOException
printFieldUnique
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public boolean shouldUseJDBCOuterJoinSyntax()
shouldUseJDBCOuterJoinSyntax
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public java.io.Writer buildSequenceObjectCreationWriter(java.io.Writer writer, java.lang.String fullSeqName, int increment, int start) throws java.io.IOException
buildSequenceObjectCreationWriter
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public java.io.Writer buildSequenceObjectDeletionWriter(java.io.Writer writer, java.lang.String fullSeqName) throws java.io.IOException
buildSequenceObjectDeletionWriter
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public java.io.Writer buildSequenceObjectAlterIncrementWriter(java.io.Writer writer, java.lang.String fullSeqName, int increment) throws java.io.IOException
buildSequenceObjectAlterIncrementWriter
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
java.io.IOException
public boolean isAlterSequenceObjectSupported()
isAlterSequenceObjectSupported
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
public void printSQLSelectStatement(org.eclipse.persistence.internal.databaseaccess.DatabaseCall call, org.eclipse.persistence.internal.expressions.ExpressionSQLPrinter printer, org.eclipse.persistence.internal.expressions.SQLSelectStatement statement)
printSQLSelectStatement
in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
|
EclipseLink 1.1.4, build 'v20100812-r7860' API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |