我有这个疑问,我在这个论坛上找到了相关信息,但我并不完全明白super()和super之间的差异。
有人可以解释一下吗?
***Parent class***
public class Bread {
public int variable1;
private int numero2;
protected int numero3;
public Bread() {
}
}
public class Bread2 extends Bread{
public Bread2() {
super();
}
}
/**There are differents examples***/
public class Bread2 extends Bread{
public Bread2(int id) {
super.numero3 = 8;
super.variable1 = 6;
}