Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
- package ClassPackage;
- /**
- *
- * @author Ryan
- */
- //Extending the parent class of user into this class
- public class Staff extends User{
- //Decleration
- private int staffID;
- private boolean isStaff;
- //Getter
- public int getStaffID() {return staffID;}
- public boolean getStaff() {return isStaff;}
- //Setter
- public void setStaffID(String StaffID) {this.staffID = staffID;}
- public void setIsStaff(boolean isStaff) {this.isStaff = isStaff;}
- //Constructor
- public Staff(int staffID, boolean isStaff) {
- staffID = 1;
- isStaff = true;
- }
- //Constructor with call to Superclass
- public Staff(int staffID, boolean isStaff, String firstName, String lastName, String password, String phoneNumber, String mobileNumber, String email, String postcode, String town, String street, String houseNo) {
- super(firstName, lastName, password, phoneNumber, mobileNumber, email, postcode, town, street, houseNo);
- this.staffID = staffID;
- this.isStaff = isStaff;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement