, some static variables and the definition of static methods are used, as well as non-static differences, which are supplemented by the following:
If all methods in a class are static and have no member variables, You need to restrict the corresponding class. The class cannot create an object, as follows:
private Arraytool () {}
//methods in the class are static, so the class is not required to create objects. To ensure that other objects are not created, the constructor of the class can be privatized.
1. Document comments
Use the Javadoc tool in the Java pseudo-machine to generate document comments and generate them using the document annotations in the code.
Note:
1, each compilation unit (class file) can have only one public class
2, the public class name (including case) must be the same as its class file. The public class may not exist in
3, a class file (*.java). The
uses the Javadoc tag: the
Javadoc tag is made up of the tag type and the private comment reference followed by "@"
the Javadoc tag has the following:
@author indicate the author of the module being developed
@ Version indicates that the versions of this class of modules
@see Reference steering, that is, related topics
@param description of a parameter in a method
@return description of the method return value
@exception Description of the exception that the method might throw
For details, refer to Bluestorm's space for the use of Javadoc annotations