📄 good.java
字号:
package Observe.good;
import java.util.Observable;
public class Good extends Observable {
private double price;
private String name;
private String madefrom;
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
this.setChanged();
this.notifyObservers("n:"+name);
}
public double getPrice() {
return price;
}
public void setPrice(double price) {
this.price = price;
this.setChanged();
this.notifyObservers(new Double(price));
}
public Good(){
super();
}
public String getMadefrom() {
return madefrom;
}
public void setMadefrom(String madefrom) {
this.madefrom = madefrom;
this.setChanged();
this.notifyObservers("m:"+madefrom);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -