mirror of
https://gitee.com/BDWare/common
synced 2025-01-10 01:44:16 +00:00
feat: update event mechanism
add second centers for event topics
This commit is contained in:
parent
f77305c0ef
commit
62533a0da1
@ -17,6 +17,7 @@ public class REvent extends SM2Verifiable implements Serializable {
|
|||||||
private String sender;
|
private String sender;
|
||||||
private REventSemantics semantics = REventSemantics.AT_LEAST_ONCE;
|
private REventSemantics semantics = REventSemantics.AT_LEAST_ONCE;
|
||||||
private boolean forward = true;
|
private boolean forward = true;
|
||||||
|
private String center;
|
||||||
|
|
||||||
public REvent(String topic, REventType type, String content, String requestID) {
|
public REvent(String topic, REventType type, String content, String requestID) {
|
||||||
this.topic = topic;
|
this.topic = topic;
|
||||||
@ -37,13 +38,6 @@ public class REvent extends SM2Verifiable implements Serializable {
|
|||||||
return content;
|
return content;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isForward() {
|
|
||||||
return forward;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setForward(boolean forward) {
|
|
||||||
this.forward = forward;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getHash() {
|
public String getHash() {
|
||||||
return hash;
|
return hash;
|
||||||
@ -73,6 +67,22 @@ public class REvent extends SM2Verifiable implements Serializable {
|
|||||||
this.semantics = semantics;
|
this.semantics = semantics;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isForward() {
|
||||||
|
return forward;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setForward(boolean forward) {
|
||||||
|
this.forward = forward;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCenter() {
|
||||||
|
return center;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCenter(String center) {
|
||||||
|
this.center = center;
|
||||||
|
}
|
||||||
|
|
||||||
public void doSignature(String pubKey, String privKey) {
|
public void doSignature(String pubKey, String privKey) {
|
||||||
this.setPublicKey(pubKey);
|
this.setPublicKey(pubKey);
|
||||||
this.doSignature(privKey);
|
this.doSignature(privKey);
|
||||||
|
Loading…
Reference in New Issue
Block a user