package mit.sql ;

public class ColumnMetaData
	implements	sql.ColumnMetaData
{
 	protected String catalogName = null ;
	public String getCatalogName() { return this.catalogName ; }

	protected int column = 0 ;
	public int getColumn() { return this.column ; }

	protected String columnClassName = null ;
	public String getColumnClassName() { return this.columnClassName ; }

	protected int columnDisplaySize = 0 ;
	public int getColumnDisplaySize() { return this.columnDisplaySize ; }

	protected String columnLabel = null ;
	public String getColumnLabel() { return this.columnLabel ; }

	protected String columnName = null ;
	public String getColumnName() { return this.columnName ; }

	protected int columnType = 0 ;
	public int getColumnType() { return this.columnType ; }

	protected String columnTypeName = null ;
	public String getColumnTypeName() { return this.columnTypeName ; }

	protected int precision = 0 ;
	public int getPrecision() { return this.precision ; }

	protected int scale = 0 ;
	public int getScale() { return this.scale ; }

	protected String schemaName = null ;
	public String getSchemaName() { return this.schemaName ; }

	protected String tableName = null ;
	public String getTableName() { return this.tableName ; }

	protected boolean autoIncrement = false ;
	public boolean isAutoIncrement() { return this.autoIncrement ; }

	protected boolean caseSensitive = false ;
	public boolean isCaseSensitive() { return this.caseSensitive ; }

	protected boolean currency = false ;
	public boolean isCurrency() { return this.currency ; }

	protected boolean definitelyWritable = false ;
	public boolean isDefinitelyWritable() { return this.definitelyWritable ; }

	protected int nullable = 0 ;
	public int getNullable() { return this.nullable ; }

	protected boolean readOnly = false ;
	public boolean isReadOnly() { return this.readOnly ; }

	protected boolean searchable = false ;
	public boolean isSearchable() { return this.searchable ; }

	protected boolean signed = false ;
	public boolean isSigned() { return this.signed ; }

	protected boolean writable = false ;
	public boolean isWritable() { return this.writable ; }

	protected ColumnMetaData
		( int column
		, java.sql.ResultSetMetaData rsMetaData
		)
		throws Exception
	{
		this.column = column ;
		if( null != rsMetaData )
		{
			this.catalogName = rsMetaData.getCatalogName( column ) ;
			this.columnClassName = rsMetaData.getColumnClassName( column ) ;
			this.columnDisplaySize = rsMetaData.getColumnDisplaySize( column ) ;
			this.columnLabel = rsMetaData.getColumnLabel( column ) ;
			this.columnName = rsMetaData.getColumnName( column ) ;
			this.columnType = rsMetaData.getColumnType( column ) ;
			this.columnTypeName = rsMetaData.getColumnTypeName( column ) ;
			this.precision = rsMetaData.getPrecision( column ) ;
			this.scale = rsMetaData.getScale( column ) ;
			this.schemaName = rsMetaData.getSchemaName( column ) ;
			this.tableName = rsMetaData.getTableName( column ) ;
			this.autoIncrement = rsMetaData.isAutoIncrement( column ) ;
			this.caseSensitive = rsMetaData.isCaseSensitive( column ) ;
			this.currency = rsMetaData.isCurrency( column ) ;
			this.definitelyWritable = rsMetaData.isDefinitelyWritable( column ) ;
			this.nullable = rsMetaData.isNullable( column ) ;
			this.readOnly = rsMetaData.isReadOnly( column ) ;
			this.searchable = rsMetaData.isSearchable( column ) ;
			this.signed = rsMetaData.isSigned( column ) ;
			this.writable = rsMetaData.isWritable( column ) ;
		}
	}

}