@Retention(value=CLASS)
@Target(value=METHOD)
public @interface On
Mark a method to be an adhoc event handler
Modifier and Type | Required Element and Description |
---|---|
java.lang.String[] |
value
Specify the event IDs
|
Modifier and Type | Optional Element and Description |
---|---|
boolean |
async
Indicate if the handler should be run synchronously with application
or asynchronously.
|
public abstract java.lang.String[] value
Specify the event IDs
public abstract boolean async
Indicate if the handler should be run synchronously with application or asynchronously.
Running job synchronously means the application will not start servicing incoming requests until the job is finished.
Running job asynchronously means the job will start in a separate thread and will not block the app from servicing incoming requests
true
if the annotated method shall be executed asynchronously or false
if the method all be executed synchronouslyCopyright © 2014–2017 ActFramework. All rights reserved.