for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Pheanstalk\Command;
use Pheanstalk\Structure\Tube;
use Pheanstalk\Structure\Workflow;
/**
* The 'deleteTube' command.
*
* Permanently deletes a tube.
* @author Paul Annesley
* @package Pheanstalk
* @license http://www.opensource.org/licenses/mit-license.php
*/
class DeleteTubeCommand extends AbstractCommand implements \Pheanstalk\ResponseParser
{
/** @var Tube $tube */
private $tube;
* @param Tube $tube
public function __construct(Tube $tube)
$this->tube = $tube;
}
* @inheritDoc
public function getGroup(): string
return 'queue';
public function getAction(): string
return 'delete';
public function getFilters(): array
return [
'id' => $this->tube->getId()
];
public function getResponseParser()
return $this;
* @return bool
public function parseResponse($responseLine, $responseData)
return $responseLine === 'OK';