本文整理了Java中org.greenrobot.eventbus.Subscribe
类的一些代码示例,展示了Subscribe
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Subscribe
类的具体详情如下:
包路径:org.greenrobot.eventbus.Subscribe
类名称:Subscribe
暂无
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(Integer event) {
lastIntEvent = event;
countIntEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe(sticky = true)
public void onEvent(MyEventInterfaceExtended event) {
countMyEventInterfaceExtended++;
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe(sticky = true)
public void onEvent(MyEventInterfaceExtended event) {
countMyEventInterfaceExtended++;
}
}
代码示例来源:origin: greenrobot/EventBus
@SuppressWarnings("unused")
@Subscribe
public void onEvent(String dummy) {
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(String event) {
lastStringEvent = event;
countStringEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(String event) {
lastStringEvent = event;
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEvent event) {
countMyEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEventInterface event) {
countMyEventInterface++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEventInterfaceExtended event) {
countMyEventInterfaceExtended++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEvent event) {
countMyEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEventExtended event) {
countMyEventExtended++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe(sticky = true)
public void onEvent(MyEventInterface event) {
countMyEventInterface++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe(sticky = true)
public void onEvent(MyEvent event) {
countMyEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(MyEventInterface event) {
countMyEventInterface++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(Object event) {
throw new RuntimeException();
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(NoSubscriberEvent event) {
throw new RuntimeException("I'm bad");
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(SubscriberExceptionEvent event) {
throw new RuntimeException("Bad");
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(String event) {
lastStringEvent = event;
countStringEvent++;
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onGenericEvent(GenericEvent<T> event) {
trackEvent(event);
}
}
代码示例来源:origin: greenrobot/EventBus
@Subscribe
public void onEvent(Object event) {
countObjectEvent.incrementAndGet();
trackEvent(event);
}
内容来源于网络,如有侵权,请联系作者删除!