Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.directory.sql.repository
Class Column

java.lang.Object
  extended by org.nuxeo.ecm.directory.sql.repository.Column
All Implemented Interfaces:
java.io.Serializable

public class Column
extends java.lang.Object
implements java.io.Serializable

An SQL column.

Author:
Florent Guillaume
See Also:
Serialized Form

Constructor Summary
Column(java.lang.String name, int sqlType, java.lang.String key)
          Creates a new column with the given name and SQL type.
 
Method Summary
 java.lang.String getDefaultValue()
           
 java.io.Serializable getFromResultSet(java.sql.ResultSet rs, int columnIndex)
           
 java.lang.String getKey()
           
 int getLength()
           
 java.lang.String getName()
           
 int getPrecision()
           
 java.lang.String getQuotedName(Dialect dialect)
           
 int getScale()
           
 int getSqlType()
           
 java.lang.String getSqlTypeString(Dialect dialect)
           
 boolean isIdentity()
           
 boolean isNullable()
           
 boolean isPrimary()
           
 void setDefaultValue(java.lang.String defaultValue)
           
 void setIdentity(boolean identity)
           
 void setLength(int length)
           
 void setNullable(boolean nullable)
           
 void setPrecision(int scale)
           
 void setPrimary(boolean primary)
           
 void setScale(int scale)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Column

public Column(java.lang.String name,
              int sqlType,
              java.lang.String key)
Creates a new column with the given name and SQL type.

Parameters:
name - the column name.
sqlType - the SQL type.
key - the associated field name.
Method Detail

getName

public java.lang.String getName()

getQuotedName

public java.lang.String getQuotedName(Dialect dialect)

getSqlType

public int getSqlType()

getKey

public java.lang.String getKey()

setIdentity

public void setIdentity(boolean identity)

isIdentity

public boolean isIdentity()

setPrimary

public void setPrimary(boolean primary)

isPrimary

public boolean isPrimary()

getLength

public int getLength()

setLength

public void setLength(int length)

getPrecision

public int getPrecision()

setPrecision

public void setPrecision(int scale)

getScale

public int getScale()

setScale

public void setScale(int scale)

setNullable

public void setNullable(boolean nullable)

isNullable

public boolean isNullable()

getDefaultValue

public java.lang.String getDefaultValue()

setDefaultValue

public void setDefaultValue(java.lang.String defaultValue)

getSqlTypeString

public java.lang.String getSqlTypeString(Dialect dialect)

getFromResultSet

public java.io.Serializable getFromResultSet(java.sql.ResultSet rs,
                                             int columnIndex)
                                      throws java.sql.SQLException
Throws:
java.sql.SQLException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.