To return
a number in a JPO, define the method with a String return type. In the
JPO, pack the number in the String. Then in the calling program (i.e.
jsp) convert this string back to a number.
JPOs can be used to calculate values and might be called during a
business object select operation. JPOs are commonly used this way in
the applications. For example:
print bus TNR select program[prog_name] -method [method_name]
will call the the method 'method_name' in the JPO 'prog_name'. If
the return value is something other than an int or Integer, the system
will call the toString method on that object and assign its value to
an RPE variable named 'prog_name'. If the method returns an int or Integer
then the JPO must set the RPE variable itself. The value stored in the
RPE variable is then returned from the select.