Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed redundant Implementation of Serializable Interface #24

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added Doubleroom.class
Binary file not shown.
Binary file added Food.class
Binary file not shown.
Binary file added Hotel.class
Binary file not shown.
Binary file added Main.class
Binary file not shown.
5 changes: 3 additions & 2 deletions Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down Expand Up @@ -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:
Expand Down Expand Up @@ -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)
{
Expand All @@ -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;
Expand Down
Binary file added NotAvailable.class
Binary file not shown.
Binary file added Singleroom.class
Binary file not shown.
Binary file added holder.class
Binary file not shown.
Binary file added write.class
Binary file not shown.