Write an abstract superclass encapsulating a vacation a


Write an abstract superclass encapsulating a vacation: A vacation has two attributes: a budget and a destination. It has an abstract method returning by how much the vacation is over or under budget.

This class has two non abstract subclasses:

One encapsulating an all-inclusive vacation; this subclass has three additional attributes: a brand (for instance ClubMed); a rating, expressed as a number of stars; and a price.

The other encapsulating a vacation bought piece meal; this subclass has two additional attributes: a set of items (hotel, meal,airfate, ...), and a set of corresponding costs.

You also need to a client class to test these two classes.

Turn in the Vacation, AllInclusiveVacation, PieceMealVacation, VacationClient java and class files and screen shots of output.

Make sure each class has the proper documentation at the top and a documentation block before the class header line.

Solution Preview :

Prepared by a verified Expert
Programming Languages: Write an abstract superclass encapsulating a vacation a
Reference No:- TGS01720453

Now Priced at $40 (50% Discount)

Recommended (91%)

Rated (4.3/5)