org.jboss.dna.common.jdbc.model.spi
Class SqlTypeInfoBean

java.lang.Object
  extended by org.jboss.dna.common.jdbc.model.spi.CoreMetaDataBean
      extended by org.jboss.dna.common.jdbc.model.spi.DatabaseNamedObjectBean
          extended by org.jboss.dna.common.jdbc.model.spi.SqlTypeInfoBean
All Implemented Interfaces:
Serializable, CoreMetaData, DatabaseNamedObject, SqlTypeInfo

public class SqlTypeInfoBean
extends DatabaseNamedObjectBean
implements SqlTypeInfo

Provides RDBMS supported standatd SQL types info.

Author:
Sergiy Litsenko
See Also:
Serialized Form

Constructor Summary
SqlTypeInfoBean()
          Default constructor
 
Method Summary
 String getCreateParams()
          Returns parameters used in creating the type (may be null)
 String getLiteralPrefix()
          Returns prefix used to quote a literal (may be null)
 String getLiteralSuffix()
          Returns suffix used to quote a literal (may be null)
 String getLocalizedTypeName()
          Returns localized version of type name (may be null).
 Integer getMaxScale()
          Returns maximum scale supported
 Integer getMinScale()
          Returns minimum scale supported
 NullabilityType getNullabilityType()
          Gets SQL type nullability
 Integer getNumberPrecisionRadix()
          Returns sql type precision radix (usually 2 or 10)
 Long getPrecision()
          Gets precision (number of fractional digits/scale) if applicable otherwise 0.
 SearchabilityType getSearchabilityType()
          Returns sql type searchability
 SqlType getSqlType()
          Gets SQL type from java.sql.Types
 Boolean isAutoIncrement()
          Returns true if sql type can be used for an auto-increment value.
 Boolean isCaseSensitive()
          Is sql type case sensitive
 Boolean isFixedPrecisionScale()
          Returns true if sql type can be a money value, for instance
 Boolean isUnsigned()
          Returns true if sql type is unsigned
 void setAutoIncrement(Boolean autoIncrement)
          Sets true if sql type can be used for an auto-increment value.
 void setCaseSensitive(Boolean caseSensitive)
          Is sql type case sensitive
 void setCreateParams(String createParams)
          Sets parameters used in creating the type (may be null)
 void setFixedPrecisionScale(Boolean fixedPrecisionScale)
          Sets true if sql type can be a money value, for instance
 void setLiteralPrefix(String literalPrefix)
          Sets prefix used to quote a literal (may be null)
 void setLiteralSuffix(String literalSuffix)
          Sets suffix used to quote a literal (may be null)
 void setLocalizedTypeName(String localizedTypeName)
          Sets localized version of type name (may be null).
 void setMaxScale(Integer maxScale)
          Sets maximum scale supported
 void setMinScale(Integer minScale)
          Sets minimum scale supported
 void setNullabilityType(NullabilityType nullabilityType)
          Sets SQL type nullability
 void setNumberPrecisionRadix(Integer numberPrecisionRadix)
          sets sql type precision radix (usually 2 or 10)
 void setPrecision(Long precision)
          Sets precision (number of fractional digits/scale) if applicable otherwise 0.
 void setSearchabilityType(SearchabilityType searchabilityType)
          Sets sql type searchability
 void setSqlType(SqlType sqlType)
          Sets SQL type from java.sql.Types
 void setUnsigned(Boolean unsigned)
          Sets true if sql type is unsigned
 
Methods inherited from class org.jboss.dna.common.jdbc.model.spi.DatabaseNamedObjectBean
addExtraProperty, deleteExtraProperty, getExtraProperties, getExtraProperty, getName, getRemarks, setName, setRemarks
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jboss.dna.common.jdbc.model.api.DatabaseNamedObject
addExtraProperty, deleteExtraProperty, getExtraProperties, getExtraProperty, getName, getRemarks, setName, setRemarks
 

Constructor Detail

SqlTypeInfoBean

public SqlTypeInfoBean()
Default constructor

Method Detail

getLocalizedTypeName

public String getLocalizedTypeName()
Returns localized version of type name (may be null). Type name is returned by DatabaseNamedObject.getName () method.

Specified by:
getLocalizedTypeName in interface SqlTypeInfo
Returns:
localized version of type name (may be null)

setLocalizedTypeName

public void setLocalizedTypeName(String localizedTypeName)
Sets localized version of type name (may be null). Type name is returned by DatabaseNamedObject.getName () method.

Specified by:
setLocalizedTypeName in interface SqlTypeInfo
Parameters:
localizedTypeName - localized version of type name (may be null)

getNullabilityType

public NullabilityType getNullabilityType()
Gets SQL type nullability

Specified by:
getNullabilityType in interface SqlTypeInfo
Returns:
SQL type nullability

setNullabilityType

public void setNullabilityType(NullabilityType nullabilityType)
Sets SQL type nullability

Specified by:
setNullabilityType in interface SqlTypeInfo
Parameters:
nullabilityType - SQL type nullability

getSqlType

public SqlType getSqlType()
Gets SQL type from java.sql.Types

Specified by:
getSqlType in interface SqlTypeInfo
Returns:
SQL type from java.sql.Types

setSqlType

public void setSqlType(SqlType sqlType)
Sets SQL type from java.sql.Types

Specified by:
setSqlType in interface SqlTypeInfo
Parameters:
sqlType - the SQL type from java.sql.Types

getPrecision

public Long getPrecision()
Gets precision (number of fractional digits/scale) if applicable otherwise 0.

Specified by:
getPrecision in interface SqlTypeInfo
Returns:
precision if applicable otherwise 0

setPrecision

public void setPrecision(Long precision)
Sets precision (number of fractional digits/scale) if applicable otherwise 0.

Specified by:
setPrecision in interface SqlTypeInfo
Parameters:
precision - precision if applicable otherwise 0

isFixedPrecisionScale

public Boolean isFixedPrecisionScale()
Returns true if sql type can be a money value, for instance

Specified by:
isFixedPrecisionScale in interface SqlTypeInfo
Returns:
true if sql type can be a money value, for instance

setFixedPrecisionScale

public void setFixedPrecisionScale(Boolean fixedPrecisionScale)
Sets true if sql type can be a money value, for instance

Specified by:
setFixedPrecisionScale in interface SqlTypeInfo
Parameters:
fixedPrecisionScale - true if sql type can be a money value, for instance

getNumberPrecisionRadix

public Integer getNumberPrecisionRadix()
Returns sql type precision radix (usually 2 or 10)

Specified by:
getNumberPrecisionRadix in interface SqlTypeInfo
Returns:
sql type precision radix (usually 2 or 10)

setNumberPrecisionRadix

public void setNumberPrecisionRadix(Integer numberPrecisionRadix)
sets sql type precision radix (usually 2 or 10)

Specified by:
setNumberPrecisionRadix in interface SqlTypeInfo
Parameters:
numberPrecisionRadix - the sql type precision radix (usually 2 or 10)

getMinScale

public Integer getMinScale()
Returns minimum scale supported

Specified by:
getMinScale in interface SqlTypeInfo
Returns:
minimum scale supported

setMinScale

public void setMinScale(Integer minScale)
Sets minimum scale supported

Specified by:
setMinScale in interface SqlTypeInfo
Parameters:
minScale - minimum scale supported

getMaxScale

public Integer getMaxScale()
Returns maximum scale supported

Specified by:
getMaxScale in interface SqlTypeInfo
Returns:
maximum scale supported

setMaxScale

public void setMaxScale(Integer maxScale)
Sets maximum scale supported

Specified by:
setMaxScale in interface SqlTypeInfo
Parameters:
maxScale - the maximum scale supported

getLiteralPrefix

public String getLiteralPrefix()
Returns prefix used to quote a literal (may be null)

Specified by:
getLiteralPrefix in interface SqlTypeInfo
Returns:
prefix used to quote a literal (may be null)

setLiteralPrefix

public void setLiteralPrefix(String literalPrefix)
Sets prefix used to quote a literal (may be null)

Specified by:
setLiteralPrefix in interface SqlTypeInfo
Parameters:
literalPrefix - the prefix used to quote a literal (may be null)

getLiteralSuffix

public String getLiteralSuffix()
Returns suffix used to quote a literal (may be null)

Specified by:
getLiteralSuffix in interface SqlTypeInfo
Returns:
suffix used to quote a literal (may be null)

setLiteralSuffix

public void setLiteralSuffix(String literalSuffix)
Sets suffix used to quote a literal (may be null)

Specified by:
setLiteralSuffix in interface SqlTypeInfo
Parameters:
literalSuffix - the suffix used to quote a literal (may be null)

getCreateParams

public String getCreateParams()
Returns parameters used in creating the type (may be null)

Specified by:
getCreateParams in interface SqlTypeInfo
Returns:
parameters used in creating the type (may be null)

setCreateParams

public void setCreateParams(String createParams)
Sets parameters used in creating the type (may be null)

Specified by:
setCreateParams in interface SqlTypeInfo
Parameters:
createParams - the parameters used in creating the type (may be null)

isCaseSensitive

public Boolean isCaseSensitive()
Is sql type case sensitive

Specified by:
isCaseSensitive in interface SqlTypeInfo
Returns:
true if sql type case sensitive

setCaseSensitive

public void setCaseSensitive(Boolean caseSensitive)
Is sql type case sensitive

Specified by:
setCaseSensitive in interface SqlTypeInfo
Parameters:
caseSensitive - the true if sql type case sensitive

getSearchabilityType

public SearchabilityType getSearchabilityType()
Returns sql type searchability

Specified by:
getSearchabilityType in interface SqlTypeInfo
Returns:
sql type searchability

setSearchabilityType

public void setSearchabilityType(SearchabilityType searchabilityType)
Sets sql type searchability

Specified by:
setSearchabilityType in interface SqlTypeInfo
Parameters:
searchabilityType - the sql type searchability

isUnsigned

public Boolean isUnsigned()
Returns true if sql type is unsigned

Specified by:
isUnsigned in interface SqlTypeInfo
Returns:
true if sql type is unsigned

setUnsigned

public void setUnsigned(Boolean unsigned)
Sets true if sql type is unsigned

Specified by:
setUnsigned in interface SqlTypeInfo
Parameters:
unsigned - true if sql type is unsigned

isAutoIncrement

public Boolean isAutoIncrement()
Returns true if sql type can be used for an auto-increment value.

Specified by:
isAutoIncrement in interface SqlTypeInfo
Returns:
true if sql type can be used for an auto-increment value.

setAutoIncrement

public void setAutoIncrement(Boolean autoIncrement)
Sets true if sql type can be used for an auto-increment value.

Specified by:
setAutoIncrement in interface SqlTypeInfo
Parameters:
autoIncrement - true if sql type can be used for an auto-increment value.


Copyright © 2008-Present JBoss a division of Red Hat. All Rights Reserved.