com.j256.ormlite.db
Class OracleDatabaseType

java.lang.Object
  extended by com.j256.ormlite.db.BaseDatabaseType
      extended by com.j256.ormlite.db.OracleDatabaseType
All Implemented Interfaces:
com.j256.ormlite.db.DatabaseType

public class OracleDatabaseType
extends com.j256.ormlite.db.BaseDatabaseType
implements com.j256.ormlite.db.DatabaseType

Oracle database type information used to create the tables, etc..

WARNING: I have not tested this unfortunately because of a lack of access to a Oracle instance. Love to get 1-2 hours of access to an database to test/tweak this. Undoubtably is it wrong. Please contact Please contact us if you'd like to help with this class.

Author:
graywatson

Nested Class Summary
protected static class OracleDatabaseType.BooleanFieldConverter
          Booleans in Oracle are stored as the character '1' or '0'.
 
Nested classes/interfaces inherited from class com.j256.ormlite.db.BaseDatabaseType
com.j256.ormlite.db.BaseDatabaseType.BooleanNumberFieldConverter
 
Field Summary
 
Fields inherited from class com.j256.ormlite.db.BaseDatabaseType
DEFAULT_SEQUENCE_SUFFIX, driver
 
Constructor Summary
OracleDatabaseType()
           
 
Method Summary
protected  void appendBigDecimalNumericType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void appendBooleanType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void appendByteArrayType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void appendByteType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
 void appendEscapedEntityName(StringBuilder sb, String name)
           
protected  void appendLongStringType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void appendLongType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
 void appendSelectNextValFromSequence(StringBuilder sb, String sequenceName)
           
protected  void appendSerializableType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void appendStringType(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, int fieldWidth)
           
protected  void configureGeneratedIdSequence(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, List<String> statementsBefore, List<String> additionalArgs, List<String> queriesAfter)
           
protected  void configureId(StringBuilder sb, com.j256.ormlite.field.FieldType fieldType, List<String> statementsBefore, List<String> additionalArgs, List<String> queriesAfter)
           
 void dropColumnArg(com.j256.ormlite.field.FieldType fieldType, List<String> statementsBefore, List<String> statementsAfter)
           
 String getDatabaseName()
           
protected  String getDriverClassName()
           
 com.j256.ormlite.field.FieldConverter getFieldConverter(com.j256.ormlite.field.DataPersister dataPersister)
           
 String getPingStatement()
           
 boolean isBatchUseTransaction()
           
 boolean isDatabaseUrlThisType(String url, String dbTypePart)
           
 boolean isEntityNamesMustBeUpCase()
           
 boolean isIdSequenceNeeded()
           
 boolean isOffsetSqlSupported()
           
 boolean isSelectSequenceBeforeInsert()
           
 
Methods inherited from class com.j256.ormlite.db.BaseDatabaseType
addPrimaryKeySql, addUniqueComboSql, appendCharType, appendColumnArg, appendCreateTableSuffix, appendDateType, appendEscapedWord, appendLimitValue, appendOffsetValue, appendShortType, configureGeneratedId, extractDatabaseTableConfig, generatedIdSqlAtEnd, generateIdSequenceName, getCommentLinePrefix, isAllowGeneratedIdInsertSupported, isCreateIfNotExistsSupported, isCreateIndexIfNotExistsSupported, isCreateTableReturnsNegative, isCreateTableReturnsZero, isLimitAfterSelect, isLimitSqlSupported, isNestedSavePointsSupported, isOffsetLimitArgument, isTruncateSupported, isVarcharFieldWidthSupported, loadDriver, setDriver
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.j256.ormlite.db.DatabaseType
addPrimaryKeySql, addUniqueComboSql, appendColumnArg, appendCreateTableSuffix, appendEscapedWord, appendLimitValue, appendOffsetValue, extractDatabaseTableConfig, generateIdSequenceName, getCommentLinePrefix, isAllowGeneratedIdInsertSupported, isCreateIfNotExistsSupported, isCreateIndexIfNotExistsSupported, isCreateTableReturnsNegative, isCreateTableReturnsZero, isLimitAfterSelect, isLimitSqlSupported, isNestedSavePointsSupported, isOffsetLimitArgument, isTruncateSupported, isVarcharFieldWidthSupported, loadDriver, setDriver
 

Constructor Detail

OracleDatabaseType

public OracleDatabaseType()
Method Detail

isDatabaseUrlThisType

public boolean isDatabaseUrlThisType(String url,
                                     String dbTypePart)
Specified by:
isDatabaseUrlThisType in interface com.j256.ormlite.db.DatabaseType

getDriverClassName

protected String getDriverClassName()
Specified by:
getDriverClassName in class com.j256.ormlite.db.BaseDatabaseType

getDatabaseName

public String getDatabaseName()
Specified by:
getDatabaseName in interface com.j256.ormlite.db.DatabaseType

appendStringType

protected void appendStringType(StringBuilder sb,
                                com.j256.ormlite.field.FieldType fieldType,
                                int fieldWidth)
Overrides:
appendStringType in class com.j256.ormlite.db.BaseDatabaseType

appendLongStringType

protected void appendLongStringType(StringBuilder sb,
                                    com.j256.ormlite.field.FieldType fieldType,
                                    int fieldWidth)
Overrides:
appendLongStringType in class com.j256.ormlite.db.BaseDatabaseType

appendByteType

protected void appendByteType(StringBuilder sb,
                              com.j256.ormlite.field.FieldType fieldType,
                              int fieldWidth)
Overrides:
appendByteType in class com.j256.ormlite.db.BaseDatabaseType

appendLongType

protected void appendLongType(StringBuilder sb,
                              com.j256.ormlite.field.FieldType fieldType,
                              int fieldWidth)
Overrides:
appendLongType in class com.j256.ormlite.db.BaseDatabaseType

appendByteArrayType

protected void appendByteArrayType(StringBuilder sb,
                                   com.j256.ormlite.field.FieldType fieldType,
                                   int fieldWidth)
Overrides:
appendByteArrayType in class com.j256.ormlite.db.BaseDatabaseType

appendSerializableType

protected void appendSerializableType(StringBuilder sb,
                                      com.j256.ormlite.field.FieldType fieldType,
                                      int fieldWidth)
Overrides:
appendSerializableType in class com.j256.ormlite.db.BaseDatabaseType

appendBigDecimalNumericType

protected void appendBigDecimalNumericType(StringBuilder sb,
                                           com.j256.ormlite.field.FieldType fieldType,
                                           int fieldWidth)
Overrides:
appendBigDecimalNumericType in class com.j256.ormlite.db.BaseDatabaseType

appendBooleanType

protected void appendBooleanType(StringBuilder sb,
                                 com.j256.ormlite.field.FieldType fieldType,
                                 int fieldWidth)
Overrides:
appendBooleanType in class com.j256.ormlite.db.BaseDatabaseType

getFieldConverter

public com.j256.ormlite.field.FieldConverter getFieldConverter(com.j256.ormlite.field.DataPersister dataPersister)
Specified by:
getFieldConverter in interface com.j256.ormlite.db.DatabaseType
Overrides:
getFieldConverter in class com.j256.ormlite.db.BaseDatabaseType

configureGeneratedIdSequence

protected void configureGeneratedIdSequence(StringBuilder sb,
                                            com.j256.ormlite.field.FieldType fieldType,
                                            List<String> statementsBefore,
                                            List<String> additionalArgs,
                                            List<String> queriesAfter)
Overrides:
configureGeneratedIdSequence in class com.j256.ormlite.db.BaseDatabaseType

configureId

protected void configureId(StringBuilder sb,
                           com.j256.ormlite.field.FieldType fieldType,
                           List<String> statementsBefore,
                           List<String> additionalArgs,
                           List<String> queriesAfter)
Overrides:
configureId in class com.j256.ormlite.db.BaseDatabaseType

dropColumnArg

public void dropColumnArg(com.j256.ormlite.field.FieldType fieldType,
                          List<String> statementsBefore,
                          List<String> statementsAfter)
Specified by:
dropColumnArg in interface com.j256.ormlite.db.DatabaseType
Overrides:
dropColumnArg in class com.j256.ormlite.db.BaseDatabaseType

appendEscapedEntityName

public void appendEscapedEntityName(StringBuilder sb,
                                    String name)
Specified by:
appendEscapedEntityName in interface com.j256.ormlite.db.DatabaseType
Overrides:
appendEscapedEntityName in class com.j256.ormlite.db.BaseDatabaseType

isIdSequenceNeeded

public boolean isIdSequenceNeeded()
Specified by:
isIdSequenceNeeded in interface com.j256.ormlite.db.DatabaseType
Overrides:
isIdSequenceNeeded in class com.j256.ormlite.db.BaseDatabaseType

appendSelectNextValFromSequence

public void appendSelectNextValFromSequence(StringBuilder sb,
                                            String sequenceName)
Specified by:
appendSelectNextValFromSequence in interface com.j256.ormlite.db.DatabaseType
Overrides:
appendSelectNextValFromSequence in class com.j256.ormlite.db.BaseDatabaseType

getPingStatement

public String getPingStatement()
Specified by:
getPingStatement in interface com.j256.ormlite.db.DatabaseType
Overrides:
getPingStatement in class com.j256.ormlite.db.BaseDatabaseType

isOffsetSqlSupported

public boolean isOffsetSqlSupported()
Specified by:
isOffsetSqlSupported in interface com.j256.ormlite.db.DatabaseType
Overrides:
isOffsetSqlSupported in class com.j256.ormlite.db.BaseDatabaseType

isBatchUseTransaction

public boolean isBatchUseTransaction()
Specified by:
isBatchUseTransaction in interface com.j256.ormlite.db.DatabaseType
Overrides:
isBatchUseTransaction in class com.j256.ormlite.db.BaseDatabaseType

isSelectSequenceBeforeInsert

public boolean isSelectSequenceBeforeInsert()
Specified by:
isSelectSequenceBeforeInsert in interface com.j256.ormlite.db.DatabaseType
Overrides:
isSelectSequenceBeforeInsert in class com.j256.ormlite.db.BaseDatabaseType

isEntityNamesMustBeUpCase

public boolean isEntityNamesMustBeUpCase()
Specified by:
isEntityNamesMustBeUpCase in interface com.j256.ormlite.db.DatabaseType
Overrides:
isEntityNamesMustBeUpCase in class com.j256.ormlite.db.BaseDatabaseType


This documentation is licensed by Gray Watson under the Creative Commons Attribution-Share Alike 3.0 License.