新增:zhub 广播 broadcast 使用主题同订阅发布
This commit is contained in:
parent
69be5ec3d7
commit
361ef58d98
@ -131,6 +131,14 @@ public abstract class ZHubClient extends AbstractConsumer implements IConsumer,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private <V> String toStr(V v) {
|
||||||
|
if (v instanceof String) {
|
||||||
|
return (String) v;
|
||||||
|
}
|
||||||
|
return JsonConvert.root().convertTo(v);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
public void send(Event t) {
|
public void send(Event t) {
|
||||||
String v = JsonConvert.root().convertTo(t.value);
|
String v = JsonConvert.root().convertTo(t.value);
|
||||||
if (v.startsWith("\"") && v.endsWith("\"")) {
|
if (v.startsWith("\"") && v.endsWith("\"")) {
|
||||||
@ -168,6 +176,7 @@ public abstract class ZHubClient extends AbstractConsumer implements IConsumer,
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
@Override
|
@Override
|
||||||
public void addEventType(EventType... eventType) {
|
public void addEventType(EventType... eventType) {
|
||||||
for (EventType type : eventType) {
|
for (EventType type : eventType) {
|
||||||
|
Loading…
Reference in New Issue
Block a user