A method is a function that describes the behavior of a class. Examples of methods are behaviors such as start service, stop service, format disk, and so on. By selecting the Methods tab, you can view all methods of the class. Methods are listed consecutively.
Methods have two parts, a signature and a body. The signature consists of the method name, the parameters names, types, and their order, and the method return type. The method body consists of a sequence of instructions.
Reading from left to right horizontally, the method contains three parts:
Return data type — The data type of the return value for this method.
Name of the method
Parameters — A comma-separated list of parameters enclosed within parentheses. Each parameter has a name and data type. Parameters that are input to the method are preceded with [IN]; parameters that are output from the method are preceded with [OUT]. A parameter can have one or more qualifiers.
In the following example, the method SetDateTime takes the input parameter Time, which is of type datetime and returns a boolean.
boolean SetDateTime([IN(true)] datetime Time); |