Course Solutions Uncategorized (Answered) : Throwing Exceptions Lotfullexception Adjust Parkinglot S Park Methods Throw Exception Inst Q28288636

(Answered) : Throwing Exceptions Lotfullexception Adjust Parkinglot S Park Methods Throw Exception Inst Q28288636

Throwing the Exceptions:

LotFullException: Adjust both of ParkingLot’spark() methods to throw this exception instead of returning falseif the ParkingLot is full and your Auto/Bicycle cannot beparked.

VehicleMissingException: Adjust ParkingLot’sfind() method to throw this exception instead of return null if thetarget vehicle is unable to be found inside the ParkingLot

ParkingSpaceOccupiedException: AdjustParkingSpace’s parkAuto() and parkBicycle() methods so that if theParkingSpace is occupied, this exception is thrown instead ofreturn false;

NegativeValueException: Adjust setSpeed() andsetPass() to throw this exception if negative values are passedinto these methods. Will need to update Vehicle Constructors!

InvalidColorException: Adjust Auto’s setColor()method to also throw this exception in addition to setting thecolor to Unknown.

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post