§3.2.(c) Result mapping
The return value of a callout method may be provided by a result mapping:
The right hand side expression of a result mapping may use the special identifier
result
to refer to the value returned by the base method.
In a method binding with parameter mappings, it is an error to use
result
as the name of a regular method argument.
Example code (Callout Parameter Mapping):
1 |
Integer absoluteValue(Integer integer) -> int abs(int i) with { |
2 |
integer.intValue() -> i, |
3 |
result <- new Integer(result) |
4 |
} |