Constructor
new AsyncRequest(obj, funcName, args)
Creates a new AsyncRequest instance.
Parameters:
Name | Type | Description |
---|---|---|
obj |
Object | Object in whose context the method should be called |
funcName |
String | Name of the function to call |
args |
Array | Array containing the arguments that should be passed to the function (optional). This option is deprecated, instead pass the arguments directly to the #run method. |
- Deprecated:
- Use the app.invokeAsync method instead (built-in into Helma as of version 1.6)
- Source:
Returns:
A new instance of AsyncRequest
Methods
evaluate()
Starts this asynchronous request.
- Deprecated:
- Use #run instead
- Source:
isAlive()
Returns true if the underlying thread is alive
- Source:
Returns:
True if the underlying thread is alive,
false otherwise.
run()
Starts this asynchronous request. Any arguments passed to
this method will be passed to the method executed by
this AsyncRequest instance.
- Source:
setDelay(millis)
Defines the delay to wait before evaluating this asynchronous request.
Parameters:
Name | Type | Description |
---|---|---|
millis |
Number | Milliseconds to wait |
- Source:
setTimeout(seconds)
Sets the timeout of this asynchronous request.
Parameters:
Name | Type | Description |
---|---|---|
seconds |
Number | Thread-timeout. |
- Source: