public @interface InnerAnnotation {
String value() default "hello";
}
public @interface OuterAnnotation {
InnerAnnotation value() default ???
}
还有一个案例:
public @interface AnotherOuterAnnotation {
InnerAnnotation[] value() default ??? UPD: {}
}
答案 0 :(得分:9)
是的,它可能:
public @interface InnerAnnotation {
String value() default "hello";
}
public @interface OuterAnnotation {
InnerAnnotation value() default @InnerAnnotation(value = "Goodbye");
}