File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
sdk-service/src/main/java/org/fisco/bcos/sdk/eventsub Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ static EventSubscribe build(Client client) throws JniException {
5555 * @param callback the EventCallback instance
5656 * @return registerId of event
5757 */
58- void subscribeEvent (EventSubParams params , EventSubCallback callback );
58+ String subscribeEvent (EventSubParams params , EventSubCallback callback );
5959
6060 /**
6161 * Unsubscribe events
Original file line number Diff line number Diff line change @@ -76,24 +76,24 @@ public void setConfigOption(ConfigOption configOption) {
7676 }
7777
7878 @ Override
79- public void subscribeEvent (EventSubParams params , EventSubCallback callback ) {
79+ public String subscribeEvent (EventSubParams params , EventSubCallback callback ) {
8080
8181 if (!params .checkParams ()) {
8282 callback .onReceiveLog ("" , EventSubStatus .INVALID_PARAMS .getStatus (), null );
83- return ;
83+ return "" ;
8484 }
8585
8686 String strParams = null ;
8787 try {
8888 strParams = objectMapper .writeValueAsString (params );
8989 } catch (JsonProcessingException e ) {
9090 logger .error ("e: " , e );
91- return ;
91+ return "" ;
9292 }
9393
9494 logger .info ("EventSub subscribeEvent, params: {}" , params );
9595
96- eventSubscribe .subscribeEvent (
96+ return eventSubscribe .subscribeEvent (
9797 groupId ,
9898 strParams ,
9999 new EventSubscribeCallback () {
You can’t perform that action at this time.
0 commit comments