Package crms.lib
Class CarReport
java.lang.Object
crms.lib.CarReport
Represents a report item for a
Car.
This class contains information about a car and its availability status.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
CarReport
Constructs aCarReportobject with the specified car and availability status.- Parameters:
car- theCarassociated with the reportisAvailable-trueif the car is available,falseotherwise
-
-
Method Details
-
getCar
Gets theCarobject associated with this report.- Returns:
- the
Carassociated with the report
-
isAvailable
public boolean isAvailable()Gets the availability status of the car.- Returns:
trueif the car is available,falseotherwise
-
equals
Compares thisCarReportto the specified object for equality.Two
CarReportobjects are considered equal if they have the sameCarID. -
hashCode
-