62,623
社区成员
发帖
与我相关
我的任务
分享
public class Restaurant{
private String name;
private Map<String, Table> tables;
private Map<String, WaitingList> waitingLists;
private List<Server> servers;
setter....//the set method of class's vars
getter....//the get method of class's vars
}
public class Party{
private String uniqueName;
private int numberOfCustomer;
setter...
getter...
/**determine if equals between two Party at same time**/
public boolean equals(){
}
public String toString(){
}
}
public class Table{
private static int count = 0;
private int number = count++;
private int size;
private boolean isFree = true;
setter of size...
public String toString(){
}
}
public class Servers{
private List<Server> servers;
/**generate a server and add to the list**/
public Server genServer(){
}
/**assign server to the party**/
public void assignServer(){
}
}
public class Server{
private static int count = 0;
private int id = count++;
}
public class Utility{
public void tableToParty(){
}
public void serverToParty(){
}
}