customer.java

来自「java开发」· Java 代码 · 共 35 行

JAVA
35
字号
package newBookingSystem;

public class Customer {

  //Customer's private properties
  private String name;
  private String phoneNumber;

  //Customer's constructor
  public Customer(String name, String tel) {
    this.name = name;
    this.phoneNumber = tel;
  }

  //Customer about name's set and get method
  public void setName(String Name) {
    name = Name;
  }

  public String getName() {
    return name;
  }

  //Customer about PhoneNumber's set and get method
  public void setPhoneNumber(String Tel) {
    phoneNumber = Tel;
  }

  public String getPhoneNumber() {
    return phoneNumber;
  }

}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?