-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMPs.java
More file actions
51 lines (44 loc) · 1.31 KB
/
MPs.java
File metadata and controls
51 lines (44 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import Users.*;
import java.util.Scanner;
/**
* Write a description of class MPs here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class MPs
{
private CameraInput camera;
private Log log;
private VAP vap;
private Exit exit;
private Entrance entrance;
private ParkingLot lot;
private InToDataBase data;
private Scanner scan;
private String ID;
private String password;
public static void main(String[] agrs)
{
Scanner scan=new Scanner(System.in);
System.out.println(" Welcome to MPs "+"\nwith your Security and Time in mind");
System.out.print("\nPlease enter user ID: ");
String ID= scan.nextLine();
System.out.print("\nPlease enter user Password: ");
String password=scan.nextIntegrate();
// open user account if it exist
Employee employee = new Employee(ID,password);
employee.typeEmployee(ID);
}
public Employee typeEmployee(String ID)
{
if( (ID.charAt(0)==1))
{
Guard guard = new Guard(ID,password,1);
}
if( (ID.charAt(0)==2))
{
Committeemember cm = new Committeemember(ID,password,2);
}
}
}