Java 9 中对 @Deprecated 注解进行了加强, 增加了 since, 和 forRemoval 属性。
/** * Returns the version in which the annotated element became deprecated. * The version string is in the same format and namespace as the value of * the {@code @since} javadoc tag. The default value is the empty * string. * * @return the version string * @since 9 */ String since() default "";注释里有这句话:版本字符串与命名空间的格式和命名空间相同
这里的版本如何指定。
如图,我指定了版本,但是没有出现划掉的标识。
你调用一下试试有没有划掉得标志
一周热门 更多>