Reusable Fields

The Reusable Fields pane, available for COBOL program-based service interfaces, is primarily for convenience. In it, create fields you want to use across operations; then copy them from there to the Interface Fields pane for each operation. The Reusable Fields pane does not change when you display a different operation.

A reusable field, whether a group item or an elementary item, defines a complex data type. For a Web Service service interface, it defines a complex data type in the WSDL file. For a Java service interface, it creates a custom record according to the CustomRecord interface defined in the Common Client Interface (CCI) from Sun.

For a Web Service, use reusable fields to define groups of interface fields used in more than one operation rather than creating the same group in each operation. If you create the same group in several different operations, its complex type is declared several times in the WSDL; however, this is illegal in WSDL where each complex type must have a unique name. A single group of reusable fields does not cause this problem.

Interface fields created from reusable fields have as their type the name of the reusable field. If you double-click the Type column in the Interface Fields pane, you see listed there all the types you have defined, as well as the native types.

Reusable fields, being type declarations and not actual fields, have no direction.