diff --git a/Doubleroom.class b/Doubleroom.class new file mode 100644 index 0000000..7a37b98 Binary files /dev/null and b/Doubleroom.class differ diff --git a/Food.class b/Food.class new file mode 100644 index 0000000..19fbcaf Binary files /dev/null and b/Food.class differ diff --git a/Hotel.class b/Hotel.class new file mode 100644 index 0000000..62418cb Binary files /dev/null and b/Hotel.class differ diff --git a/Main.class b/Main.class new file mode 100644 index 0000000..1161f67 Binary files /dev/null and b/Main.class differ diff --git a/Main.java b/Main.java index 2255c0a..9d60225 100755 --- a/Main.java +++ b/Main.java @@ -49,7 +49,7 @@ class Singleroom implements Serializable this.gender=gender; } } -class Doubleroom extends Singleroom implements Serializable +class Doubleroom extends Singleroom { String name2; String contact2; @@ -356,7 +356,6 @@ static void bill(int rn,int rtype) static void deallocate(int rn,int rtype) { - int j; char w; switch (rtype) { case 1: @@ -487,6 +486,7 @@ public void run() { FileOutputStream fout=new FileOutputStream("backup"); ObjectOutputStream oos=new ObjectOutputStream(fout); oos.writeObject(hotel_ob); + oos.close(); } catch(Exception e) { @@ -508,6 +508,7 @@ public static void main(String[] args){ FileInputStream fin=new FileInputStream(f); ObjectInputStream ois=new ObjectInputStream(fin); Hotel.hotel_ob=(holder)ois.readObject(); + ois.close(); } Scanner sc = new Scanner(System.in); int ch,ch2; diff --git a/NotAvailable.class b/NotAvailable.class new file mode 100644 index 0000000..bda0408 Binary files /dev/null and b/NotAvailable.class differ diff --git a/Singleroom.class b/Singleroom.class new file mode 100644 index 0000000..90ddb8f Binary files /dev/null and b/Singleroom.class differ diff --git a/holder.class b/holder.class new file mode 100644 index 0000000..422e296 Binary files /dev/null and b/holder.class differ diff --git a/write.class b/write.class new file mode 100644 index 0000000..1760ae3 Binary files /dev/null and b/write.class differ