0
Answer

Websocket sendasync response from request

Photo of Sharp C

Sharp C

5y
796
1
I have a connection class which will maintain a web socket connection to my server. In my connection class, I have a function task < product > getproduct; AWebsocket.sendasync But the response from server has to be handled in onmessage event, but I would like caller who make use of my class will get the response from the function call, how can I pick up the response from onmessage and return directly from getproduct function?

Answers (0)