|
|||||||||||
前のクラス 次のクラス | フレームあり フレームなし | ||||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Objectorg.seasar.framework.container.factory.AbstractAnnotationHandler
AnnotationHandlerの抽象クラスです。
このクラスでは、主にクラス、メソッド、フィールドに書かれたアノーテションを取得します。 アノーテションから、コンポーネントに対しての各定義の作成はサブクラスで行います。
フィールドの概要 | |
protected static String |
ASPECT
ASPECTアノテーションを表す定数名です。 |
protected static String |
AUTO_BINDING
COMPONENTアノテーションのautoBinding属性「自動バインディング定義」を表すキーです。 |
protected static String |
BINDING_SUFFIX
Bindingアノテーションとして識別するための定数です。 |
protected static String |
BINDING_TYPE
BindingアノテーションのbindingType属性「バインディングタイプ」を表すキーです。 |
protected static String |
COMPONENT
COMPONENTアノテーションを表す定数名です。 |
protected static String |
DESTROY_METHOD
DestroyMethodアノテーションを表す定数名です。 |
protected static String |
EXTERNAL_BINDING
COMPONENTアノテーションのexternalBinding属性「外部バインディング定義」を表すキーです。 |
protected static String |
INIT_METHOD
InitMethodアノテーションを表す定数名です。 |
protected static String |
INSTANCE
COMPONENTアノテーションのinstance属性「インスタンス定義」を表すキーです。 |
protected static String |
INTER_TYPE
InterTypeアノテーションを表す定数名です。 |
protected static String |
INTERCEPTOR
ASPECTアノテーションのinterceptor属性「インターセプター定義」を表すキーです。 |
protected static String |
NAME
COMPONENTアノテーションのname属性「コンポーネント名」を表すキーです。 |
protected static String |
POINTCUT
ASPECTアノテーションのpointcut属性「ポイントカット定義」を表すキーです。 |
protected static String |
VALUE
各アノテーション内のvalue属性「VALUE」を表すキーです。 |
コンストラクタの概要 | |
AbstractAnnotationHandler()
|
メソッドの概要 | |
void |
appendDI(ComponentDef componentDef)
コンポーネント定義にプロパティ定義を追加します。 |
ComponentDef |
createComponentDef(Class componentClass,
InstanceDef instanceDef)
コンポーネント名、インスタンス定義を指定してコンポーネント定義を作成します。 |
ComponentDef |
createComponentDef(Class componentClass,
InstanceDef instanceDef,
AutoBindingDef autoBindingDef)
コンポーネントクラス、インスタンス定義、自動バインディング定義を指定してコンポーネント定義を作成します。 |
protected ComponentDef |
createComponentDef(Class componentClass,
String name,
InstanceDef instanceDef,
AutoBindingDef autoBindingDef,
boolean externalBinding)
指定したコンポーネントクラスからコンポーネント定義を作成します。 |
ComponentDef |
createComponentDef(String className,
InstanceDef instanceDef)
クラス名、インスタンス定義を指定してコンポーネント定義を作成します。 |
ComponentDef |
createComponentDef(String className,
InstanceDef instanceDef,
AutoBindingDef autoBindingDef)
クラス名、インスタンス定義、自動バインディング定義を指定してコンポーネント定義を作成します。 |
ComponentDef |
createComponentDef(String className,
InstanceDef instanceDef,
AutoBindingDef autoBindingDef,
boolean externalBinding)
クラス名、インスタンス定義、自動バインディング定義、外部バインディングの有無を指定してコンポーネント定義を作成します。 |
protected PropertyDef |
createPropertyDef(String propertyName,
String expression,
String bindingTypeName,
String accessTypeName)
プロパティ定義を作成します。 |
protected AutoBindingDef |
getAutoBindingDef(String name)
自動バインディング定義を返します。 |
protected InstanceDef |
getInstanceDef(String name)
インスタンス定義を返します。 |
protected InstanceDef |
getInstanceDef(String name,
InstanceDef defaultInstanceDef)
インスタンス定義を返します。 |
boolean |
isDestroyMethodRegisterable(ComponentDef cd,
String methodName)
コンポーネント定義にdestroyメソッドが追加可能かどうかを返します。 |
protected boolean |
isFieldInjectionTarget(Field field)
指定したフィールドがインジェクション可能かどうかの判定を行います。 |
boolean |
isInitMethodRegisterable(ComponentDef cd,
String methodName)
コンポーネント定義に初期化メソッドが追加可能かどうかを返します。 |
クラス java.lang.Object から継承したメソッド |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
インタフェース org.seasar.framework.container.factory.AnnotationHandler から継承したメソッド |
appendAspect, appendDestroyMethod, appendInitMethod, appendInterType, createComponentDef, createPropertyDef, createPropertyDef |
フィールドの詳細 |
protected static final String COMPONENT
protected static final String NAME
protected static final String INSTANCE
protected static final String AUTO_BINDING
protected static final String BINDING_SUFFIX
protected static final String BINDING_TYPE
protected static final String EXTERNAL_BINDING
protected static final String VALUE
protected static final String ASPECT
protected static final String INTER_TYPE
protected static final String INIT_METHOD
protected static final String DESTROY_METHOD
protected static final String INTERCEPTOR
protected static final String POINTCUT
コンストラクタの詳細 |
public AbstractAnnotationHandler()
メソッドの詳細 |
public ComponentDef createComponentDef(String className, InstanceDef instanceDef)
AnnotationHandler
の記述:
AnnotationHandler
内の createComponentDef
className
- クラス名instanceDef
- インスタンス定義
public ComponentDef createComponentDef(String className, InstanceDef instanceDef, AutoBindingDef autoBindingDef)
AnnotationHandler
の記述:
AnnotationHandler
内の createComponentDef
className
- クラス名instanceDef
- インスタンス定義autoBindingDef
- 自動バインディング定義
public ComponentDef createComponentDef(String className, InstanceDef instanceDef, AutoBindingDef autoBindingDef, boolean externalBinding)
AnnotationHandler
の記述:
AnnotationHandler
内の createComponentDef
className
- クラス名instanceDef
- インスタンス定義autoBindingDef
- 自動バインディング定義externalBinding
- 外部バインディングの有無
public ComponentDef createComponentDef(Class componentClass, InstanceDef instanceDef)
AnnotationHandler
の記述:
AnnotationHandler
内の createComponentDef
componentClass
- コンポーネントクラスinstanceDef
- インスタンス定義
public ComponentDef createComponentDef(Class componentClass, InstanceDef instanceDef, AutoBindingDef autoBindingDef)
AnnotationHandler
の記述:
AnnotationHandler
内の createComponentDef
componentClass
- コンポーネントクラスinstanceDef
- インスタンス定義autoBindingDef
- 自動バインディング定義
public void appendDI(ComponentDef componentDef)
AnnotationHandler
の記述:
AnnotationHandler
内の appendDI
componentDef
- コンポーネント定義protected InstanceDef getInstanceDef(String name, InstanceDef defaultInstanceDef)
指定した名前のインスタンス定義が存在しない場合、デフォルトのインスタンス定義を返します。
name
- インスタンス定義の種類defaultInstanceDef
- デフォルトのインスタンス定義(singleton)
protected InstanceDef getInstanceDef(String name)
name
- インスタンス定義の種類
protected AutoBindingDef getAutoBindingDef(String name)
name
- 自動バインディング定義の種類
protected ComponentDef createComponentDef(Class componentClass, String name, InstanceDef instanceDef, AutoBindingDef autoBindingDef, boolean externalBinding)
以下の設定がある場合はおのおのコンポーネント定義に設定します。
componentClass
- コンポーネントクラスname
- コンポーネント名instanceDef
- インスタンス定義autoBindingDef
- 自動バインディング定義externalBinding
- 外部バインディングの有無
protected PropertyDef createPropertyDef(String propertyName, String expression, String bindingTypeName, String accessTypeName)
propertyName
- プロパティ名expression
- 引数定義の値となる式bindingTypeName
- バインディングタイプ定義accessTypeName
- アクセスタイプ定義
public boolean isInitMethodRegisterable(ComponentDef cd, String methodName)
AnnotationHandler
の記述:
AnnotationHandler
内の isInitMethodRegisterable
cd
- コンポーネント定義methodName
- 初期化の対象にするメソッド名
true、そうでない場合はfalse
を返す。
public boolean isDestroyMethodRegisterable(ComponentDef cd, String methodName)
AnnotationHandler
の記述:
AnnotationHandler
内の isDestroyMethodRegisterable
cd
- コンポーネント定義methodName
- 初期化の対象にするメソッド名
true、そうでない場合はfalse
を返す。
protected boolean isFieldInjectionTarget(Field field)
static
または、final
でない場合はインジェクションが可能になります。
field
- フィールド
static
、final
でない場合はtrue
、そうでない場合はfalse
を返す。
|
|||||||||||
前のクラス 次のクラス | フレームあり フレームなし | ||||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |