Monday, July 27, 2009

Help me using netbeans..!!?

Define a class named WaterTank which would represent a typical cylindrical water tank. The


class should contain two properties:





description - stores the description of the tank.


diameter - stores the measurement of the tank’s diameter.


height - stores the measurement of the tank’s height.





a. Write at least two (2) constructor methods for the class.


b. Provide getter and setter methods for each data members.


c. Write a method named getArea( ) which returns the area of the tank.


d. Write a method getWaterVolume(double waterHeight) which returns the volume of water


inside the tank given height of the water inside the tank.


f. Write a method named getMaximumCapacity( ) which would return the maximum volume of


water (capacity) that the tank can hold.


e. Override both the toString( ) and equals( ) methods that are inherited from the Object class.

Help me using netbeans..!!?
This seems like a relatively easy program to construct, why would you need netbeans?





If you're referring to the UI i'd recommend eclipse (or notepad if you don't want to learn a new program).





If you really want to pursue netbeans perhaps take a look at www.java-tips.org


No comments:

Post a Comment