public function isFreed(Io $io) : bool { $id = (int) $io->getResource(); return !isset($this->sockets[$id]) || $io !== $this->sockets[$id]; }