使用 Javadoc 1.5,我无法创建指向枚举值的 @link。
我想创建一个这样的枚举:
public enum Planet {
/**
* MERCURY is a fun place.
*/
MERCURY,
/**
* VENUS is more fun.
*/
VENUS,
/**
* But nothing beats the Earth.
*/
EARTH,
/**
* Others we know nothing about.
*/
OTHERS
}
然后使用类似这样的链接来参考地球的Javadoc:
{@link Planet.EARTH}
我也尝试了{@link Planet#EARTH}
样式,但没有成功。
请问有人知道这到底可不可行?
{@link EARTH}
,因为它之后会变成红色。 - undefined