Perform action (<perform> element)

The Perform action invokes a method belonging to a Java class that you have imported (see Creating an imported type for a Java class).

You can invoke a method in many other contexts besides the Perform action. However, the Perform action is useful in certain scenarios, for example, when you want to invoke a method that does not return a value.

Some of the contexts, other than the Perform action, in which you can invoke a method are as follows: In general, outside the Perform action, you can invoke a method in any context in which the value returned by the method is valid.