jimm.datavision.source.sql
Class SQLTable

java.lang.Object
  extended by jimm.datavision.source.Table
      extended by jimm.datavision.source.sql.SQLTable
All Implemented Interfaces:
Identity, Nameable

public class SQLTable
extends Table

Represents a database table.

Author:
Jim Menard, jimm@io.com

Field Summary
protected  java.util.HashMap colCacheMap
           
protected  java.sql.DatabaseMetaData dbmd
           
 
Fields inherited from class jimm.datavision.source.Table
columns, dataSource, name
 
Constructor Summary
SQLTable(Database database, java.lang.String name, java.sql.DatabaseMetaData dbmd)
          Constructor.
 
Method Summary
 java.util.Iterator columns()
          Returns an iterator over the columns in this table.
 Column findColumn(java.lang.Object colIdObj)
          Given a column id, returns the column that has that id.
protected  void loadColumns()
           
protected  void loadColumnsUsing(java.lang.String schemaName, java.lang.String tableName)
           
 
Methods inherited from class jimm.datavision.source.Table
addColumn, getId, getName, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dbmd

protected java.sql.DatabaseMetaData dbmd

colCacheMap

protected java.util.HashMap colCacheMap
Constructor Detail

SQLTable

public SQLTable(Database database,
                java.lang.String name,
                java.sql.DatabaseMetaData dbmd)
Constructor.

Parameters:
database - the database in which this table resides
name - the table's name
dbmd - database metadata information
Method Detail

findColumn

public Column findColumn(java.lang.Object colIdObj)
Description copied from class: Table
Given a column id, returns the column that has that id. If no column with the specified id exists, returns null.

Overrides:
findColumn in class Table
Returns:
a column, or null if no column with the specified id exists

columns

public java.util.Iterator columns()
Description copied from class: Table
Returns an iterator over the columns in this table.

Overrides:
columns in class Table
Returns:
an iterator over the columns in this table

loadColumns

protected void loadColumns()

loadColumnsUsing

protected void loadColumnsUsing(java.lang.String schemaName,
                                java.lang.String tableName)