package com.feige.beans;
public class Customer extends Person {
private String customerId;
private String phone;
public Customer() {
}
public Customer(String customerId, String phone) {
super(); // 調(diào)用父類構(gòu)造方法,可寫可不寫
this.customerId = customerId;
this.phone = phone;
}
public Customer(String name, String sex, String pwd, int age, String customerId, String phone) {
super(name, sex, pwd, age);
this.customerId = customerId;
this.phone = phone;
}
@Override
public String toString() {
return "Customer{" +
"customerId='" + customerId + '\'' +
", phone='" + phone + '\'' +
"} " + super.toString();
}
public String getCustomerId() {
return customerId;
}
public void setCustomerId(String customerId) {
this.customerId = customerId;
}
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
}