Java Basic - Function 3

 Java Documentation

Java documentation lets us know about functions that java has built in and already recognizes.

It tells us about function descriptions, variable types and how to use them.

Java is owned  by Oracle and they contain all the documentation online.

It is the holy bible that all java developers use.

Lets create out own Java documentation below.

The usual basic documentation is as follow:

/**
*General description of a function
*
*@param a first input parameter, named a
*@param b second paramter, named b
*
*@return description of return value
*/

Now for a more real example eg dimension(double width, double depth, double height);
/**
*This volume function calculates the volume of a given rectangle by multiplying its sides
*
*@param width is the width dimension  (double)
*@param depth is the depth dimension  (double)
*@param height is the height dimension (double)
*
*@return volume  is the dimension (as a double)
*/

There is automatic software that can make this documentation.


Comments

Popular posts from this blog

Java Basics - Variable and Data Types Part 1

Java Basics - Variable and Data Types Part 2

OOP - Objects and Classes