/**
 * Shapes creates and manipulates various geometric shapes.
 */
public class Shapes {

    public static void main (String[] args) {

        // Create two new geometrical shape objects, and store
        // references to these objects.
        Rectangle box  = new Rectangle();
        Cylinder  tube = new Cylinder();

        // Initialize the object referred to by box to have a width of 10,
        // a height of 20, and to be the colour red.
        box.init(10, 20, "red");

        // 
        // 
        tube.init(5, 15, "blue");
        
        // 
        // 
        box.setColour("purple");

        // 
        // 
        tube.scale(10);

        // 
        // 
        tube.shrink(2, 4, 2, 3);

        // 
        // 
        box.scale(2, 3);

        // 
        // 
        tube.setColour("green");

        // 
        // 
        tube.scale(5, 2);

        // 
        // 
        box.scale(5);

        // 
        // 
        int newScale = box.scale(2, 3, 1);

        // 
        // 
        box.scale(newScale);

        // Display the area of the object referred to by box.
        System.out.print("Area of box: ");
        System.out.println(box.area());

        // Display the volume of the object referred to by tube.
        System.out.print("Volume of tube: ");
        System.out.println(tube.volume());

        // Display the dimensions of the object referred to by box.
        System.out.println(box.infoReport());

        // Display the dimensions of the object referred to by tube.
        System.out.println(tube.getInfo());
    }
}

