public function delete($key, $onResponse = null, $time = 0)
    {
        $this->getConnectionByKey($key, function ($conn) use ($key, $time, $onResponse) {
            if (!$conn->connected) {
                return;
            }
            if ($onResponse !== null) {
                $conn->onResponse->push($onResponse);
                $conn->checkFree();
            }
            $conn->writeln('delete ' . $this->config->prefix->value . $key . ' ' . $time);
        });
    }
public function delete($key, $onResponse = null, $time = 0)
    {
        $this->getConnectionByKey($key, function ($conn) use ($key, $time, $onResponse) {
            if (!$conn->connected) {
                return;
            }
            if ($onResponse !== null) {
                $conn->onResponse->push($onResponse);
                $conn->checkFree();
            }
            $conn->writeln('delete ' . $this->config->prefix->value . $key . ' ' . $time);
        });
    }
public function delete ( $ key , $ onResponse = null , $ time = 0 ) { $ this -> getConnectionByKey ( $ key , function ( $ conn ) use ( $ key , $ time , $ onResponse ) { if ( ! $ conn -> connected ) { return ; } if ( $ onResponse !== null ) { $ conn -> onResponse -> push ( $ onResponse ) ; $ conn -> checkFree ( ) ; } $ conn -> writeln ( 'delete ' . $ this -> config -> prefix -> value . $ key . ' ' . $ time ) ; } ) ; }
Deletes the key
@param  string $key Key
@param  callable $onResponse Callback called when the request complete
@param  integer $time Time to block this key
@callback $onResponse ( )
@return void
Deletes the key