我有以下枚举:
public enum Months {
JAN(31),
FEB(28),
MAR(31),
APR(30),
MAY(31),
JUN(30),
JUL(31),
AUG(31),
SEP(30),
OCT(31),
NOV(30),
DEC(31);
private final byte DAYS; //days in the month
private Months(byte numberOfDays){
this.DAYS = numberOfDays;
}//end constructor
public byte getDays(){
return this.Days;
}//end method getDays
}//end enum Months
尽管我传递了一个有效的字节参数,但它给了我一个错误,上面写着“构造函数 Months(int) 未定义” 。我究竟做错了什么?