| Issue 24: | @CompositeのEvaluateTypeを正しく機能させる | |
| 1 person starred this issue and may be notified of changes. | Back to list |
EvaluateTypeはAnnotationの階層をどこからよみとって
AnnotationDescを作成するかという機能を保有する。
以下の2つの状態を持つ。
・INCLUDE_THIS(1とする)
・PARENT_ONLY(2とする)
たとえば以下のようなアノテーションを考えてみる。
@Retention(RetentionPolicy.RUNTIME)
@Target( { ElementType.TYPE })
@Composite
@Test1
@Test2
public static @interface Test3 {
}
デフォルトの状態は、INCLUDE_THISなので
AnnotationDescは@Test3, @Test1, @Test2の3つが作成される。
仮に@Composite(value = EvaluateType.PARENT_ONLY)とした場合は
@Compositeがついているアノテーション自体は無視され、
AnnotationDescは@Test1, @Test2の3つが作成される。
Feb 12, 2008
Project Member
#1
shinpei.ohtani@gmail.com
Status:
Fixed
|