Question: Practice: Using java, take the given Meeting Scheduler System(MSS) program and implement it using a GUI (No Command Line). Guidelines: 1. Your application should have
Practice:
Using java, take the given Meeting Scheduler System(MSS) program and implement it using a GUI (No Command Line).
Guidelines:
1. Your application should have a GUI. All interaction should be through the GUI. The command line should never be used.
2. At any time, the user should be able to save all the information on a file.
3. When a program start the user can upload all the information from a file
MeetingScheuler.Java
public class MeetingScheduler { private static int getMeetingsCount(HashMap } Participant.Java public class Participant { private String firstName; private String lastName; private String phone; public Participant(String fname,String lname)//constructor { firstName=fname.toUpperCase();//eliminates confusion from user input lastName=lname.toUpperCase(); } public String getFirstName() { return firstName; } public String getLastName() { return lastName; } public String getPhone() { return phone; } public void setPhone(String phone) { this.phone = phone; } public String getName() { return firstName+" "+lastName; } } Room.Java public class Room { private int roomNo; private Meeting meetings[]; private int count; public Room(int num)//constructor { roomNo=num; //9 slots for meetings starting from 9:00 hr , 10:00....5:00hr meetings=new Meeting[9]; count=0; } public int getRoomNum() { return roomNo; } public boolean addMeeting(Meeting meeting)//adds a meeting { int startHour=meeting.getStartHour(); //meetings can be from 9 to 5 if(startHour<9 || starthour>17) return false; int index=startHour-9; //caluclate what this meeting index is. 9:00 will be at index 0, 10:00 at index 1 and so on if(meetings[index]==null) //if no other meetings is assigned already { meetings[index]=meeting; count++; return true; } else return false; } public boolean isSlotAvailable(int startHour)//determines if meeting can be scheduled at this hour { if(startHour<9 || starthour>17) return false; int index=startHour-9; //caluclate what this meeting index is. 9:00 will be at index 0, 10:00 at index 1 and so on return (meetings[index]==null); } public boolean cancelMeeting(int startHour)//delete meeting { //meetings can be from 9 to 5 if(startHour<9 || starthour>17) return false; int index=startHour-9; //caluclate what this meeting index is. 9:00 will be at index 0, 10:00 at index 1 and so on if(meetings[index]==null) { return false; } else { meetings[index]=null; count--; return true; } } public int getNumMeetings() { return count; } public Meeting getMeeting(int startHour) { //meetings can be from 9 to 5 if(startHour<9 || starthour>17) return null; int index=startHour-9; //caluclate what this meeting index is. 9:00 will be at index 0, 10:00 at index 1 and so on return meetings[index]; } public boolean isAttending(Participant p)//checks to see whos at the meeting { Meeting m; for(int i=0;i Meeting.Java public class Meeting { private String name; private Room room; private int startHour; private ArrayList Thank you in advance, please let me know if you need more information
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
