public @interface InnerAnnotation {
String value() default "hello";
}
public @interface OuterAnnotation {
InnerAnnotation value() default ???
}
And one more case:
public @interface AnotherOuterAnnotation {
InnerAnnotation[] value() default ??? UPD: {}
}
Yes, its possible:
public @interface InnerAnnotation {
String value() default "hello";
}
public @interface OuterAnnotation {
InnerAnnotation value() default @InnerAnnotation(value = "Goodbye");
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With