Methods in general

A method in Java is a sequence of commands that are invoked in a predefined order.
A method declaration, or the method signature, is the API for the method and contains all essential information that needs to be known in order to call it. A method signature can be divided into several parts:

– The name of the method
– The input parameters of the method.
– The return type of the method.
– Possible exceptions that are thrown from the method.
– Method modifiers.

The format looks like this:

These different parts of the method signature will be explained in different sections under the ‘Methods’ category sections.

Search for more Java info on this site here:
Custom Search

Please type any questions here.