Package org.greenrobot.eventbus
Annotation Type Subscribe
-
@Documented @Retention(RUNTIME) @Target(METHOD) public @interface Subscribe
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description int
priority
Subscriber priority to influence the order of event delivery.boolean
sticky
If true, delivers the most recent sticky event (posted withEventBus.postSticky(Object)
) to this subscriber (if event available).ThreadMode
threadMode
-
-
-
Element Detail
-
threadMode
ThreadMode threadMode
- Default:
- org.greenrobot.eventbus.ThreadMode.POSTING
-
-
-
sticky
boolean sticky
If true, delivers the most recent sticky event (posted withEventBus.postSticky(Object)
) to this subscriber (if event available).- Default:
- false
-
-
-
priority
int priority
Subscriber priority to influence the order of event delivery. Within the same delivery thread (ThreadMode
), higher priority subscribers will receive events before others with a lower priority. The default priority is 0. Note: the priority does *NOT* affect the order of delivery among subscribers with differentThreadMode
s!- Default:
- 0
-
-