

// A user-defined data types that stores data about an rocket.

// The public fields (often none) and public constructors and methods
// form the Rocket API (application programming interface)

class Rocket {

	//*** fields
	private String name = null;
	private double fuelWeight = 0.0;
	private String fuelType = null;

	// final fields cannot be modified AFTER the constructor is invoked.
	// they can be modified in constructors.
	private final boolean manable = true;

	// static fields are shared by ALL instances of a class
	public static int rocketCount = 0;

    //*** A constructor that sets the
	public Rocket(String name, double fuelWeight, String fuelType, boolean manable) {
		this.name = name;
		this.fuelWeight = fuelWeight;
		this.fuelType = fuelType;
		this.manable = manable;

		rocketCount++;
	}

	// Allow users to create rockets with the default field values.
    public Rocket() {}

    //*** methods to get the values of the fields
	public static String getName() { return name; }
	public double getFuelWeight() { return fuelWeight; }
	public String getFuelType() { return fuelType; }
	public boolean getManable() { return this.manable; }

    //*** methods to set the values of the fields
	public void setName(String n) { name = n; }
	public void setFuelWeight(double w) { fuelWeight = w; }
	public void setFuelType(String t) { fuelType = t; }
}
