java 构造方法doc注释位置

来源:百度知道 编辑:UC知道 时间:2024/06/04 10:41:11
java 构造方法的注释应该加在什么位置,才能被javadoc.exe提取,最后出现在图示位置,请举例说明!
还是给出我的部分代码吧:
package com.wxws.sms.data;
/**
* Data.java
* 商品类、会员类
* @author w
* @version v1.1
*/
public class Data {
/*商品信息*/
/**
* 商品名
*/
public String[] goodsName = new String[50];
/**
* 商品价格
*/
public double[] goodsPrice = new double[50];

/*会员信息*/
/**
* 会员编号
*/
public int[] custNo = new int[100];
/**
* 会员生日
*/
public String[] custBirth = new String[100];
/**
* 会员积分
*/
public int[] custScore = new int[100];

/*管理员*/
/**
* 管理员
*/
public Manager manager = new Manager();

/**
* 建立商品数据和客户信息
*/<

跟普通方法一样,只要在方法前注释就行了,如这是String的构造方法注释

/**
* Initializes a newly created {@code String} object so that it represents
* the same sequence of characters as the argument; in other words, the
* newly created string is a copy of the argument string. Unless an
* explicit copy of {@code original} is needed, use of this constructor is
* unnecessary since Strings are immutable.
*
* @param original
* A {@code String}
*/
public String(String original) {
int size = original.count;
char[] originalValue = original.value;
char[] v;
if (originalValue.length > size) {
// The array representing the String is bigger than the new
// String itself. Perhaps this constructor is being called
// in order to trim the baggage, so make a copy of the array.
int off = original.offset;
v = Arrays.copyOf