MCPcopy Create free account
hub / github.com/apache/cassandra-nodejs-driver / cancel

Method cancel

lib/operation-state.js:61–70  ·  view source on GitHub ↗

* Marks the operation as cancelled, clearing all callbacks and timeouts.

()

Source from the content-addressed store, hash-verified

59 * Marks the operation as cancelled, clearing all callbacks and timeouts.
60 */
61 cancel() {
62 if (this._state !== state.init) {
63 return;
64 }
65 if (this._timeout !== null) {
66 clearTimeout(this._timeout);
67 }
68 this._state = state.cancelled;
69 this._callback = utils.noop;
70 }
71
72 /**
73 * Determines if the operation can be written to the wire (when it hasn't been cancelled or it hasn't timed out).

Callers 1

setCompletedMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected