You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 879f196
Browse filesBrowse the repository at this point in the historyBrowse files
Adds an optional serial attribute to @background:
@background(serial="some_id")
This idea comes from androidannotations#309:
androidannotations#309
The principle of this implementation is to keep a separate queue for
each serial identifier, and to give each task to the (unique) executor
only after the previous task with the same serial identifier (if any)
has completed execution.
It guarantees that all tasks with the same serial identifier will be
called in the order, one at a time (but not necessarily on the same
thread).
It is still compatible with the delay attribute. For example:
@background(serial="some_id", delay=2000)
executes the task in background after at least 2 seconds *and* after the
previous task requested with serial="some_id" (if any) have completed
execution.
Copy file name to clipboardExpand all lines: AndroidAnnotations/androidannotations-api/src/main/java/org/androidannotations/annotations/Background.java
Copy file name to clipboardExpand all lines: AndroidAnnotations/androidannotations/src/main/java/org/androidannotations/processing/BackgroundProcessor.java
+3-2Lines changed: 3 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -55,12 +55,13 @@ public void process(Element element, JCodeModel codeModel, EBeanHolder holder) t
0 commit comments