org.seasar.doma.extension.gen
クラス EntityDescFactory

java.lang.Object
  上位を拡張 org.seasar.doma.extension.gen.EntityDescFactory

public class EntityDescFactory
extends Object

エンティティ記述のファクトリです。

作成者:
taedium

入れ子のクラスの概要
protected static class EntityDescFactory.EntityPropertyInfo
          エンティティプロパティ情報です。
 
フィールドの概要
protected  ClassDescSupport classDescSupport
          クラス記述のサポートクラス
protected  EntityPropertyDescFactory entityPropertyDescFactory
          エンティティプロパティ記述のファクトリ
protected  NamingType namingType
          ネーミング規約
protected  String originalStatesPropertyName
          元のステートを表すプロパティの名前
protected  String packageName
          パッケージ名
protected  boolean showCatalogName
          カタログ名を表示する場合 true
protected  boolean showDbComment
          データベースのコメントを表示する場合 true
protected  boolean showSchemaName
          スキーマ名を表示する場合 true
protected  boolean showTableName
          テーブル名を表示する場合 true
protected  Class<?> superclass
          スーパークラス
protected  boolean useAccessor
          アクセッサーを使用する場合 true
protected  boolean useListener
          エンティティリスナーを使用する場合 true
 
コンストラクタの概要
EntityDescFactory(String packageName, Class<?> superclass, EntityPropertyDescFactory entityPropertyDescFactory, NamingType namingType, String originalStatesPropertyName, boolean showCatalogName, boolean showSchemaName, boolean showTableName, boolean showDbComment, boolean useAccessor, boolean useListener)
          インスタンスを構築します。
 
メソッドの概要
 EntityDesc createEntityDesc(TableMeta tableMeta)
          エンティティ記述を作成します。
protected  Set<EntityDescFactory.EntityPropertyInfo> getSuperclassEntityPropertyInfo()
          スーパークラスに定義されたエンティティプロパティの情報のセットを返します。
protected  void handleEntityPropertyDesc(EntityDesc entityDesc, TableMeta tableMeta)
          エンティティプロパティ記述を処理します。
protected  void handleImportName(EntityDesc entityDesc, TableMeta tableMeta)
          インポート名を処理します。
protected  void handleShowTableName(EntityDesc entityDesc, TableMeta tableMeta)
          カタログ名を表示するかどうか処理します。
protected  void handleSimpleName(EntityDesc entityDesc, TableMeta tableMeta)
          単純名を処理します。
protected  boolean isNameDifferentBetweenEntityAndTable(EntityDesc entityDesc)
          エンティティ名とテーブル名が異なる場合 trueを返します。
protected  void mergeEntityProperty(EntityPropertyDesc dest, EntityDescFactory.EntityPropertyInfo src)
          エンティティプロパティ記述にエンティティプロパティ情報をマージします。
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

packageName

protected final String packageName
パッケージ名


entityPropertyDescFactory

protected final EntityPropertyDescFactory entityPropertyDescFactory
エンティティプロパティ記述のファクトリ


namingType

protected final NamingType namingType
ネーミング規約


originalStatesPropertyName

protected String originalStatesPropertyName
元のステートを表すプロパティの名前


showCatalogName

protected final boolean showCatalogName
カタログ名を表示する場合 true


showSchemaName

protected final boolean showSchemaName
スキーマ名を表示する場合 true


showTableName

protected final boolean showTableName
テーブル名を表示する場合 true


showDbComment

protected final boolean showDbComment
データベースのコメントを表示する場合 true


useAccessor

protected final boolean useAccessor
アクセッサーを使用する場合 true


useListener

protected final boolean useListener
エンティティリスナーを使用する場合 true


superclass

protected final Class<?> superclass
スーパークラス


classDescSupport

protected final ClassDescSupport classDescSupport
クラス記述のサポートクラス

コンストラクタの詳細

EntityDescFactory

public EntityDescFactory(String packageName,
                         Class<?> superclass,
                         EntityPropertyDescFactory entityPropertyDescFactory,
                         NamingType namingType,
                         String originalStatesPropertyName,
                         boolean showCatalogName,
                         boolean showSchemaName,
                         boolean showTableName,
                         boolean showDbComment,
                         boolean useAccessor,
                         boolean useListener)
インスタンスを構築します。

パラメータ:
packageName - パッケージ名
superclass - スーパークラス
entityPropertyDescFactory - エンティティプロパティ記述のファクトリ
namingType - ネーミング規約
showCatalogName - カタログ名を表示する場合 true
showSchemaName - スキーマ名を表示する場合 true
showTableName - テーブル名を表示する場合 true
useAccessor - アクセッサーを使用する場合 true
useListener - エンティティリスナーを使用する場合 true
メソッドの詳細

createEntityDesc

public EntityDesc createEntityDesc(TableMeta tableMeta)
エンティティ記述を作成します。

パラメータ:
tableMeta - テーブルメタデータ
戻り値:
エンティティ記述

handleSimpleName

protected void handleSimpleName(EntityDesc entityDesc,
                                TableMeta tableMeta)
単純名を処理します。

パラメータ:
entityDesc - エンティティ記述
tableMeta - テーブルメタデータ

handleShowTableName

protected void handleShowTableName(EntityDesc entityDesc,
                                   TableMeta tableMeta)
カタログ名を表示するかどうか処理します。

パラメータ:
entityDesc - エンティティ記述
tableMeta - テーブルメタデータ

isNameDifferentBetweenEntityAndTable

protected boolean isNameDifferentBetweenEntityAndTable(EntityDesc entityDesc)
エンティティ名とテーブル名が異なる場合 trueを返します。

パラメータ:
entityDesc - エンティティ記述
戻り値:
エンティティ名とテーブル名が異なる場合 true

handleEntityPropertyDesc

protected void handleEntityPropertyDesc(EntityDesc entityDesc,
                                        TableMeta tableMeta)
エンティティプロパティ記述を処理します。

パラメータ:
entityDesc - エンティティ記述
tableMeta - テーブルメタデータ

mergeEntityProperty

protected void mergeEntityProperty(EntityPropertyDesc dest,
                                   EntityDescFactory.EntityPropertyInfo src)
エンティティプロパティ記述にエンティティプロパティ情報をマージします。

パラメータ:
dest - エンティティプロパティ記述
src - エンティティプロパティ情報
導入されたバージョン:
1.7.0

getSuperclassEntityPropertyInfo

protected Set<EntityDescFactory.EntityPropertyInfo> getSuperclassEntityPropertyInfo()
スーパークラスに定義されたエンティティプロパティの情報のセットを返します。

戻り値:
スーパークラスに定義されたエンティティプロパティの情報のセット
導入されたバージョン:
1.7.0

handleImportName

protected void handleImportName(EntityDesc entityDesc,
                                TableMeta tableMeta)
インポート名を処理します。

パラメータ:
entityDesc - エンティティ記述
tableMeta - テーブルメタデータ


Copyright © 2009-2013 The Seasar Foundation. All Rights Reserved.