Invoke
Invokes an object method and returns the result of the invoked method.
Method Signature
Invoke(object=[any], method=[string], arguments=[any])Arguments
Argument
Type
Required
Description
Default
object
any
true
method
string
false
The name of the method to invoke
arguments
any
false
An array of positional arguments or a struct of named arguments to pass into the method.
Examples
Invoke a Java Method
Invokes the size method on a new HashMap object, which should return 0
invoke( createObject( "java", "java.util.HashMap" ), "size" );
Result: 0
Invoke a method on a component
Invokes the method named 'test' on the component Test.bx with one parameter
Invoke a method on a webservice with one argument
Invokes the method named 'test' on the webservice Test.bx with one argument
Invoke a method on a webservice with multiple arguments
Invokes the method named 'test' on the webservice Test.bx with multiple arguments
Additional Examples
Related
Last updated
Was this helpful?
