cinema booking system
807607Jan 13 2007 — edited Jan 15 2007erm i am a newbie in java,i am doing a cinema booking system,for the seat domain class can help me check whether my method put correctly,for my seat domain i wan to have 100 seat for each theatre,n each seat will contain customerid if booked.
can help me check whether my method put correctly pls
Seat
public class Seat {
public static final boolean AVAILABLE=true;
public static final boolean BOOKED=false;
private String seatID;
private boolean status;
private String customerID;
public Seat(String seatID,String customerID)
{
this.seatID=seatID;
this.customerID=customerID;
status=AVAILABLE;
}
public String getSeatid(){
return seatID;
}
public void setStatus(boolean status) {
this.status=status;
}
public void doBooking(String customerID) {
status = false;
this.customerID = customerID;
}
public void unBooking() {
status = true;
customerID = "";
}
public boolean getStatus() {
return status;
}
public String getCustomerid(){
return customerID;
}
public String toString() {
return "Seat ID="+seatID+"\nStatus:"+status+"\nCustomer ID:"+customerID;
}
}
Message was edited by:
saisai_01988