docs: public synchronized void cancel() {
          // If the packet collector has already been cancelled, do nothing.
          if (cancelled) {
              return;
          }
  
          cancelled = true;
          connection.removeStanzaCollector(this);
          notifyAll();
  
          if (collectorToReset != null) {
              collectorToReset.cancel();
          }
      }