code: void observe(FolderObserver observer) {
      synchronized (idleMutex) {
        this.observer = observer;
        pushedData = new PushedData();
        idleAcknowledged.set(false);
      }
    }
docs: Registers a FolderObserver to receive events happening with a particular
  folder. Typically an IMAP IDLE feature. If called multiple times, will
  overwrite the currently set observer.