第1个回答 2014-04-12
package com.eunm;
public enum Day {
Sunday {
public String getName() {
return "周日";
}
},
Monday {
public String getName() {
return "周一";
}
},
Tuesday {
public String getName() {
return "周二";
}
},
Wednesday {
public String getName() {
return "周三";
}
},
Thurday {
public String getName() {
return "周四";
}
},
Friday {
public String getName() {
return "周五";
}
},
Saturday {
public String getName() {
return "周六";
}
};
public abstract String getName();
@Override
public String toString() {
return getName();
}
}