1 17 package org.apache.ws.jaxme.sqls; 18 19 import java.sql.Types ; 20 21 import org.apache.ws.jaxme.sqls.impl.ColumnImpl; 22 23 24 27 public interface Column { 28 public interface Name extends SQLFactory.Ident { 29 } 30 31 public interface Type { 32 34 public String getName(); 35 38 public int getJDBCType(); 39 40 public static final Type BIGINT = new ColumnImpl.TypeImpl("BIGINT", Types.BIGINT); 41 public static final Type BINARY = new ColumnImpl.TypeImpl("BINARY", Types.BINARY); 42 public static final Type BIT = new ColumnImpl.TypeImpl("BIT", Types.BIT); 43 public static final Type CHAR = new ColumnImpl.TypeImpl("CHAR", Types.CHAR); 44 public static final Type DATE = new ColumnImpl.TypeImpl("DATE", Types.DATE); 45 public static final Type INTEGER = new ColumnImpl.TypeImpl("INTEGER", Types.INTEGER); 46 public static final Type FLOAT = new ColumnImpl.TypeImpl("FLOAT", Types.FLOAT); 47 public static final Type DOUBLE = new ColumnImpl.TypeImpl("DOUBLE", Types.DOUBLE); 48 public static final Type SMALLINT = new ColumnImpl.TypeImpl("SMALLINT", Types.SMALLINT); 49 public static final Type TIME = new ColumnImpl.TypeImpl("TIME", Types.TIME); 50 public static final Type TIMESTAMP = new ColumnImpl.TypeImpl("TIMESTAMP", Types.TIMESTAMP); 51 public static final Type TINYINT = new ColumnImpl.TypeImpl("TINYINT", Types.TINYINT); 52 public static final Type VARCHAR = new ColumnImpl.TypeImpl("VARCHAR", Types.VARCHAR); 53 public static final Type VARBINARY = new ColumnImpl.TypeImpl("VARBINARY", Types.VARBINARY); 54 public static final Type BLOB = new ColumnImpl.TypeImpl("CLOB", Types.BLOB); 55 public static final Type OTHER = new ColumnImpl.TypeImpl("OTHER", Types.OTHER); 56 public static final Type CLOB = new ColumnImpl.TypeImpl("CLOB", Types.CLOB); 57 } 58 59 61 public Table getTable(); 62 63 65 public Name getName(); 66 67 70 public String getQName(); 71 72 74 public Type getType(); 75 76 78 public boolean isPrimaryKeyPart(); 79 80 83 public void setNullable(boolean pNullable); 84 85 88 public boolean isNullable(); 89 90 92 public boolean isStringColumn(); 93 94 96 public boolean isBinaryColumn(); 97 98 100 public void setCustomData(Object pData); 101 102 105 public Object getCustomData(); 106 107 109 public boolean isVirtual(); 110 } 111 | Popular Tags |