Search for question
Question

Define a child class of Seat called AirlineSeat.

It must have:

* price(float-private)

* seatNumber(int-private)

* available(boolean-private)

* customerName(string-private)

* A constructor which takes in seatNumber(int), price(float), color(String), reclines (boolean)

"It must call a constructor in its parent to set color and reclines (with the arguments to this

constructor) as well as 17 for width, and 18 for height.

"It should also set available to true, customerName to "", price and seatNumber with

the remaining parameters.

* Create getters for seatNumber and available.

A method called occupySeat which takes in a customer's name and sets the

customerName attribute to it, it will also set available to false.

*An override of toString/ToString which returns an unsold seat like:

Available seat 20 costs $300.

*Or a seat which has been sold like:

Sold seat 20 cost $300 sold to How!

*NOTE: 20 should be the actual seatNumber, and $300 should be the actual seat cost. Howl

should be the actual customerName.