PHPDaemon\BoundSocket\Generic::disable PHP Method

disable() public method

Disable all events of sockets
public disable ( ) : void
return void
    public function disable()
    {
        if (!$this->enabled) {
            return;
        }
        $this->enabled = false;
        if ($this->ev instanceof \Event) {
            $this->ev->del();
        } elseif ($this->ev instanceof \EventListener) {
            $this->ev->disable();
        }
    }