消息设置headers

通过event bus发送的消息还可以包含头文件。

这可以通过发送或发布时提供DeliveryOptions指定:

DeliveryOptions options = new DeliveryOptions();
options.addHeader("some-header", "some-value");
eventBus.send("news.uk.sport", "Yay! Someone kicked a ball", options);
Copyright © quanke.name 2016 all right reserved,powered by Gitbook该文件修订时间: 2016-09-06 03:18:18

results matching ""

    No results matching ""