|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Objectorg.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.seasar.doma.extension.gen.task.AbstractTask
org.seasar.doma.extension.gen.task.Gen
public class Gen
コードを生成します。
次のコードを生成できます。
フィールドの概要 | |
---|---|
protected DaoConfig |
daoConfig
Daoの設定 |
protected DaoDelegateDescFactory |
daoDelegateDescFactory
Daoデリゲート記述のファクトリ |
protected DaoDescFactory |
daoDescFactory
Dao記述のファクトリ |
protected javax.sql.DataSource |
dataSource
データソース |
protected GenDialect |
dialect
方言 |
protected DialectNameAttribute |
dialectName
方言名 |
protected java.lang.String |
driverClassName
Driver のサブタイプのクラス名 |
protected EntityConfig |
entityConfig
エンティティの設定 |
protected EntityDescFactory |
entityDescFactory
エンティティ記述のファクトリ |
protected EntityListenerDescFactory |
entityListenerDescFactory
エンティティリスナー記述のファクトリ |
protected EntityPropertyClassNameResolver |
entityPropertyClassNameResolver
エンティティプロパティのクラス名リゾルバ |
protected EntityPropertyDescFactory |
entityPropertyDescFactory
エンティティプロパティ記述のファクトリ |
protected java.lang.String |
genDialectClassName
GenDialect のサブタイプのクラス名 |
protected Generator |
generator
ジェネレータ |
protected java.lang.String |
ignoredTableNamePattern
対象としないテーブル名の正規表現 |
protected java.lang.String |
password
JDBC接続パスワード |
protected java.lang.String |
schemaName
対象とするテーブルが属するスキーマ名 |
protected SqlConfig |
sqlConfig
SQLの設定 |
protected SqlDescFactory |
sqlDescFactory
SQL記述ファクトリ |
protected TableMetaReader |
tableMetaReader
テーブルメタデータ |
protected java.lang.String |
tableNamePattern
対象とするテーブル名の正規表現 |
protected java.util.List<java.lang.String> |
tableTypes
対象とするテーブルの型のリスト |
protected java.lang.String |
templateEncoding
テンプレートのエンコーディング |
protected java.io.File |
templatePrimaryDir
テンプレートを格納するプライマリディレクトリ、使用しない場合 null |
protected java.lang.String |
url
JDBC接続URL |
protected java.lang.String |
user
JDBC接続ユーザー |
protected java.lang.String |
versionColumnNamePattern
バージョンカラム名のパターン。 |
クラス org.seasar.doma.extension.gen.task.AbstractTask から継承されたフィールド |
---|
globalFactory, globalFactoryClassName |
クラス org.apache.tools.ant.Task から継承されたフィールド |
---|
target, taskName, taskType, wrapper |
クラス org.apache.tools.ant.ProjectComponent から継承されたフィールド |
---|
description, location, project |
コンストラクタの概要 | |
---|---|
Gen()
|
メソッドの概要 | |
---|---|
DaoConfig |
createDaoConfig()
Daoの設定を作成します。 |
protected DaoDelegateDescFactory |
createDaoDelegateDescFactory()
Daoデリゲート記述ファクトリを作成します。 |
protected DaoDescFactory |
createDaoDescFactory()
Dao記述ファクトリを作成します。 |
protected javax.sql.DataSource |
createDataSource()
データソースを作成します。 |
EntityConfig |
createEntityConfig()
エンティティの設定を作成します。 |
protected EntityDescFactory |
createEntityDescFactory()
エンティティ記述ファクトリを作成します。 |
protected EntityListenerDescFactory |
createEntityListenerDescFactory()
エンティティリスナー記述ファクトリを作成します。 |
protected EntityPropertyClassNameResolver |
createEntityPropertyClassNameResolver()
エンティティプロパティのクラス名リゾルバを作成します。 |
protected EntityPropertyDescFactory |
createEntityPropertyDescFactory()
グローバルファクトリを作成します。 |
protected Generator |
createGenerator()
ジェネレータを作成します。 |
SqlConfig |
createSqlConfig()
SQLの設定を作成します。 |
protected SqlDescFactory |
createSqlDescFactory()
SQL記述ファクトリを作成します。 |
protected TableMetaReader |
createTableMetaReader()
テーブルメタデータを作成します。 |
protected void |
doPrepare()
サブクラスで準備します。 |
protected void |
doRun()
サブクラスで実行します。 |
protected void |
doValidate()
サブクラスで検証します。 |
protected void |
generateDao(DaoDesc daoDesc)
DaoのJavaコードを生成します。 |
protected void |
generateDaoDelegate(DaoDelegateDesc daoDelegateDesc)
DaoデリゲートのJavaコードを生成します。 |
protected void |
generateEntity(EntityDesc entityDesc)
エンティティのJavaコードを生成します。 |
protected void |
generateEntityListener(EntityListenerDesc entityListenerDesc)
|
protected void |
generateSql(DaoDesc daoDesc,
SqlDesc sqlDesc)
SQLを生成します。 |
void |
setDialectName(DialectNameAttribute dialectName)
方言名を設定します。 |
void |
setDriverClassName(java.lang.String driverClassName)
Driver のサブタイプのクラス名を設定します。 |
void |
setGenDialectClassName(java.lang.String genDialectClassName)
GenDialect のサブタイプのクラス名を設定します。 |
void |
setIgnoredTableNamePattern(java.lang.String ignoredTableNamePattern)
対象としないテーブル名の正規表現を設定します。 |
void |
setPassword(java.lang.String password)
JDBC接続パスワードを設定します。 |
void |
setSchemaName(java.lang.String schemaName)
対象とするテーブルが属するスキーマ名を設定します。 |
void |
setTableNamePattern(java.lang.String tableNamePattern)
対象とするテーブル名の正規表現を設定します。 |
void |
setTableTypes(java.lang.String tableTypes)
カンマまたは空白で区切られたテーブルの型のリストを設定します |
void |
setTemplateEncoding(java.lang.String templateEncoding)
テンプレートのエンコーディングを設定します。 |
void |
setTemplatePrimaryDir(java.io.File templatePrimaryDir)
テンプレートを格納するプライマリディレクトリを設定します。 |
void |
setUrl(java.lang.String url)
JDBC接続URLを設定します。 |
void |
setUser(java.lang.String user)
JDBC接続ユーザーを設定します。 |
void |
setVersionColumnNamePattern(java.lang.String versionColumnNamePattern)
バージョンカラム名のパターンを設定します。 |
クラス org.seasar.doma.extension.gen.task.AbstractTask から継承されたメソッド |
---|
execute, forName, newInstance, prepare, run, setGlobalFactoryClassName, validate |
クラス org.apache.tools.ant.Task から継承されたメソッド |
---|
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType |
クラス org.apache.tools.ant.ProjectComponent から継承されたメソッド |
---|
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject |
クラス java.lang.Object から継承されたメソッド |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
フィールドの詳細 |
---|
protected DialectNameAttribute dialectName
protected java.lang.String genDialectClassName
GenDialect
のサブタイプのクラス名
protected java.lang.String driverClassName
Driver
のサブタイプのクラス名
protected java.lang.String user
protected java.lang.String password
protected java.lang.String url
protected java.lang.String schemaName
protected java.lang.String tableNamePattern
protected java.lang.String ignoredTableNamePattern
protected java.util.List<java.lang.String> tableTypes
protected java.lang.String versionColumnNamePattern
org.seasar.doma.Versino
が注釈されます。
protected java.lang.String templateEncoding
protected java.io.File templatePrimaryDir
null
protected GenDialect dialect
protected javax.sql.DataSource dataSource
protected TableMetaReader tableMetaReader
protected EntityPropertyClassNameResolver entityPropertyClassNameResolver
protected EntityDescFactory entityDescFactory
protected EntityListenerDescFactory entityListenerDescFactory
protected EntityPropertyDescFactory entityPropertyDescFactory
protected DaoDescFactory daoDescFactory
protected DaoDelegateDescFactory daoDelegateDescFactory
protected SqlDescFactory sqlDescFactory
protected Generator generator
protected EntityConfig entityConfig
protected DaoConfig daoConfig
protected SqlConfig sqlConfig
コンストラクタの詳細 |
---|
public Gen()
メソッドの詳細 |
---|
public void setUser(java.lang.String user)
user
- JDBC接続ユーザーpublic void setPassword(java.lang.String password)
password
- JDBC接続パスワードpublic void setUrl(java.lang.String url)
url
- JDBC接続URLpublic void setDriverClassName(java.lang.String driverClassName)
Driver
のサブタイプのクラス名を設定します。
driverClassName
- Driver
のサブタイプのクラス名public void setDialectName(DialectNameAttribute dialectName)
dialectName
- 方言名public void setGenDialectClassName(java.lang.String genDialectClassName)
GenDialect
のサブタイプのクラス名を設定します。
genDialectClassName
- GenDialect
のサブタイプのクラス名public void setSchemaName(java.lang.String schemaName)
schemaName
- 対象とするテーブルが属するスキーマ名public void setTableNamePattern(java.lang.String tableNamePattern)
tableNamePattern
- 対象とするテーブル名の正規表現public void setIgnoredTableNamePattern(java.lang.String ignoredTableNamePattern)
ignoredTableNamePattern
- 対象としないテーブル名の正規表現public void setTableTypes(java.lang.String tableTypes)
tableTypes
- カンマまたは空白で区切られたテーブルの型のリストpublic void setVersionColumnNamePattern(java.lang.String versionColumnNamePattern)
versionColumnNamePattern
- バージョンカラム名のパターンpublic void setTemplateEncoding(java.lang.String templateEncoding)
templateEncoding
- テンプレートのエンコーディングpublic void setTemplatePrimaryDir(java.io.File templatePrimaryDir)
templatePrimaryDir
- テンプレートを格納するプライマリディレクトリ、使用しない場合 null
public EntityConfig createEntityConfig()
public DaoConfig createDaoConfig()
public SqlConfig createSqlConfig()
protected void doValidate()
AbstractTask
の記述:
AbstractTask
内の doValidate
protected void doPrepare()
AbstractTask
の記述:
AbstractTask
内の doPrepare
protected javax.sql.DataSource createDataSource()
protected TableMetaReader createTableMetaReader()
protected EntityPropertyClassNameResolver createEntityPropertyClassNameResolver()
protected EntityPropertyDescFactory createEntityPropertyDescFactory()
protected EntityDescFactory createEntityDescFactory()
protected EntityListenerDescFactory createEntityListenerDescFactory()
protected DaoDescFactory createDaoDescFactory()
protected DaoDelegateDescFactory createDaoDelegateDescFactory()
protected SqlDescFactory createSqlDescFactory()
protected Generator createGenerator()
protected void doRun()
AbstractTask
の記述:
AbstractTask
内の doRun
protected void generateEntity(EntityDesc entityDesc)
entityDesc
- エンティティ記述protected void generateEntityListener(EntityListenerDesc entityListenerDesc)
protected void generateDao(DaoDesc daoDesc)
daoDesc
- Dao記述protected void generateDaoDelegate(DaoDelegateDesc daoDelegateDesc)
daoDelegateDesc
- Daoデリゲート記述protected void generateSql(DaoDesc daoDesc, SqlDesc sqlDesc)
daoDesc
- Dao記述sqlDesc
- SQL記述
|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |