@Link(type=ALIAS_FOR) @Documented @Retention(value=RUNTIME) @Target(value={METHOD,ANNOTATION_TYPE}) public @interface AliasFor
Link
的子注解。表示“原始属性”将作为“关联属性”的别名。
Link
、ForceAliasFor
或MirrorFor
一起使用时,将只有被声明在最上面的注解会生效Link
,
RelationType.ALIAS_FOR
Modifier and Type | Optional Element and Description |
---|---|
Class<? extends Annotation> |
annotation
产生关联的注解类型,当不指定时,默认指注释的属性所在的类
|
String |
attribute
annotation() 指定注解中关联的属性 |
@Link(annotation=Link.class, attribute="annotation", type=FORCE_ALIAS_FOR) public abstract Class<? extends Annotation> annotation
@Link(annotation=Link.class, attribute="attribute", type=FORCE_ALIAS_FOR) public abstract String attribute
annotation()
指定注解中关联的属性Copyright © 2024. All rights reserved.