MCPcopy Index your code
hub / github.com/socketio/socket.io-client-java / clearAcks

Method clearAcks

src/main/java/io/socket/client/Socket.java:292–300  ·  view source on GitHub ↗

Clears the acknowledgement handlers upon disconnection, since the client will never receive an acknowledgement from the server.

()

Source from the content-addressed store, hash-verified

290 * the server.
291 */
292 private void clearAcks() {
293 for (Ack ack : this.acks.values()) {
294 if (ack instanceof AckWithTimeout) {
295 ((AckWithTimeout) ack).onTimeout();
296 }
297 // note: basic Ack objects have no way to report an error, so they are simply ignored here
298 }
299 this.acks.clear();
300 }
301
302 private void onpacket(Packet<?> packet) {
303 if (!this.nsp.equals(packet.nsp)) return;

Callers 1

oncloseMethod · 0.95

Calls 1

onTimeoutMethod · 0.45

Tested by

no test coverage detected