com.infoteria.asteria.flowbuilder2.sqlbuilder
Class TableProviderByConnection

java.lang.Object
  |
  +--com.infoteria.asteria.flowbuilder2.sqlbuilder.TableProviderByConnection
All Implemented Interfaces:
TableProvider

public class TableProviderByConnection
extends Object
implements TableProvider

コネクションをラップしたTableProviderです。


Constructor Summary
TableProviderByConnection(com.infoteria.asteria.flowbuilder2.connection.ConnectionProvider provider, RDBConnectionEntry entry)
           
 
Method Summary
static TableProvider createProvider(com.infoteria.asteria.flowbuilder2.connection.ConnectionProvider cp, BaseObject obj, String propName)
           
 String getSchemaName()
           
 Table getTable(String name)
           
 String[] getTableNames()
           
 boolean isHSQLDB()
           
 boolean isOracle()
           
 boolean isTestSupported()
           
 List selectTest(String sql, VariableList params, int max, boolean bHeader)
           
 List selectTest(String sql, VariableList params, int max, boolean bHeader, Map sqlTypeMap)
           
 com.infoteria.asteria.util.rdb.SchemasInfo supportsSchemasInformation()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TableProviderByConnection

public TableProviderByConnection(com.infoteria.asteria.flowbuilder2.connection.ConnectionProvider provider,
                                 RDBConnectionEntry entry)
Method Detail

createProvider

public static TableProvider createProvider(com.infoteria.asteria.flowbuilder2.connection.ConnectionProvider cp,
                                           BaseObject obj,
                                           String propName)
                                    throws IOException

getSchemaName

public String getSchemaName()
Description copied from interface: TableProvider
デフォルトのスキーマ名
Specified by:
getSchemaName in interface TableProvider

getTableNames

public String[] getTableNames()
Description copied from interface: TableProvider
使用可能なテーブル名の配列
テーブル名は「スキーマ名.テーブル名」のように「.」で区切られる。
(DBによってはスキーマ名がないこともある)
Specified by:
getTableNames in interface TableProvider

isOracle

public boolean isOracle()
Description copied from interface: TableProvider
TABLEの供給元がOracleである場合にtrue
(SQLの方言に対応するために必要)
Specified by:
isOracle in interface TableProvider

isHSQLDB

public boolean isHSQLDB()

getTable

public Table getTable(String name)
Description copied from interface: TableProvider
指定のテーブルのTableクラス
Specified by:
getTable in interface TableProvider

isTestSupported

public boolean isTestSupported()
Description copied from interface: TableProvider
selectTestがサポートされているかどうか
Specified by:
isTestSupported in interface TableProvider

selectTest

public List selectTest(String sql,
                       VariableList params,
                       int max,
                       boolean bHeader)
                throws SQLException
Description copied from interface: TableProvider
select文のテスト実行。結果はString[]のListで返される。 selectTest の5番目の引数をnullにしたのと同じ動作になります。
Specified by:
selectTest in interface TableProvider
Following copied from interface: com.infoteria.asteria.sqlbuilder.model.TableProvider
Parameters:
sql - SQL文。パラメータなどはRDBGetやSQLCallで使用しているそのままの形式で埋め込んでおく
params - SQLパラメータ。SQL文中のパラメータに対応
max - returnに含める最大行数
bHeader - 結果のListにヘッダ行を含めるかどうか。trueの場合はListの1行目はSELECT結果ではなく列名
Returns:
SELECT実行結果がString[]のListとして返される

selectTest

public List selectTest(String sql,
                       VariableList params,
                       int max,
                       boolean bHeader,
                       Map sqlTypeMap)
                throws SQLException
Description copied from interface: TableProvider
select文のテスト実行。結果はString[]のListで返される。
Specified by:
selectTest in interface TableProvider
Following copied from interface: com.infoteria.asteria.sqlbuilder.model.TableProvider
Parameters:
sql - SQL文。パラメータなどはRDBGetやSQLCallで使用しているそのままの形式で埋め込んでおく
params - SQLパラメータ。SQL文中のパラメータに対応
max - returnに含める最大行数
bHeader - 結果のListにヘッダ行を含めるかどうか。trueの場合はListの1行目はSELECT結果ではなく列名
sqlTypeMap - params のそれぞれのフィールド名(String)と java.sql.Types の型(Integer)のマップ 実行時に対応する型が見つからない場合は VARCHAR 扱いになります
Returns:
SELECT実行結果がString[]のListとして返される

supportsSchemasInformation

public com.infoteria.asteria.util.rdb.SchemasInfo supportsSchemasInformation()
                                                                      throws SQLException
Description copied from interface: TableProvider
サポートしているスキーマ情報を返します
Specified by:
supportsSchemasInformation in interface TableProvider
Following copied from interface: com.infoteria.asteria.sqlbuilder.model.TableProvider
Returns:
サポートスキーマ情報