Your design should be closely modeled on that of the Rectangle and Square classes discussed earlier. Develop a detailed specification for the Circle class, which identifies the purpose of the class, its instance variables and methods. Designate which information will be hidden and which parts of the class will make up its interface.
Type the specification using the same text editor you use for typing the program itself. Enclose the specification within a Java comment block and save it in a file named Circle.java. This file will be the file you use for defining the Circle class. The comment will serve as documentation for the program.
A comment block in Java begins with either ``/*'' or ``/** `` and ends with ``*/''. It can extend over multiple lines. As explained in Appendix A, comments that begin with ``/**'' are documentation comments, which can be automatically turned into documentation for the class using software that comes with the Java Development Kit (JDK). You would use documentation comments to describe a class's specification. Here's an example format that you can use:
/**
* Class Name: Circle
*
* ... ( the rest of your specification )
*
*/