/** * Write a description of class Car here. * * @author (your name) * @version (a version number or a date) */ public class Car { //instance variables private String manufacturer; private String model; private double price; private Plate plateNumber; /** * * Constructs a car. * * */ Car (String manufacturer, String model, double price) { this.manufacturer = manufacturer; this.model = model; this.price = price; plateNumber = new Plate(); } /** * * Gets the price * * @return the price */ public double getPrice() { return price; } /** * * Sets the price * * @param newPrice the new price */ public void setPrice( double newPrice ) { price = newPrice; } /** * * Displays a car. * * @return String Displays the manufacturer, model and plateNumber. */ public String toString( ) { return String.format("%s\t%s\t%s", manufacturer, model, plateNumber); } }