Fujitsu J Adapter Class Generator Portable Generator User Manual


 
60 Chapter 5. Adapter Class Reference
Instance Method
Explanation
A non-public instance method (non-static method) is mapped to a COBOL object
method.
Expansion format
METHOD-ID. internal-method-name AS "external-method-name" [OVERRIDE].
...
DATA DIVISION.
LINKAGE SECTION.
[parameter ...]
[return-value ...]
PROCEDURE DIVISION [USING parameter ...] [RETURNING return-value]
[RAISING exception-class-name].
END METHOD internal-method-name.
Generation rules
1. The internal method name is internally used by the J adapter class generator
and cannot be viewed from the class user.
2. The external method name is used to identify the method. The class user
identifies the method with the external method name.
3. An external method name is generated according to the following rules:
JavaMethodName[-nn]
- A Java method name is used as is as a COBOL method name.
- If a same method name has already been assigned, the second and
subsequent method names are each suffixed with a hyphen "-" followed by a
two-digit number (01 to 99) to prevent name duplication. (See "
Numbering
names
.")
- A name exceeding 160 characters is truncated after the 160th character.
4. When a parameter is declared for the method, the corresponding parameter is
generated. See "
Data types
" for the correspondence between parameter data
types.
5. When a return value is declared for the method, the corresponding return value
is generated. See "
Data types
" for the correspondence between return value
data types.
6. When an exception is declared for the constructor, the RAISING specification is
generated.