Show TOC

Background documentationType-Specific Getter Methods Locate this document in the navigation structure

 

The class JCO.Structure contains type-specific getter methods such as getString() for the data type string. Applications normally use the appropriate getter method, You can of course use another getter method: SAP JCo then tries to convert the field content to a relevant data type. If this conversion is unsuccessful (for example, if a string field contains the value John Smith, and you call getDate, an exception is thrown.

The table below lists all the type-specific getter methods. The method getValue() can be used to call the content of a field generically. This method returns a Java object.

This graphic is explained in the accompanying text.

Fig.: Type-Specific Getter Methods