我对如何将我的课程转换为Integer
. 例子:
public class IntegerField extends Field {
private Integer value;
public IntegerField(Integer value) {
super();
this.value = value;
}
public int intValue() {
return value;
}
}
我该怎么做:
IntegerField a = new IntegerField(8);
Integer b = (Integer) a;
谢谢!