_tube = $tube; $this->_delay = $delay; } /* (non-phpdoc) * @see Command::getCommandLine() */ public function getCommandLine() { return sprintf( 'pause-tube %s %u', $this->_tube, $this->_delay ); } /* (non-phpdoc) * @see ResponseParser::parseResponse() */ public function parseResponse($responseLine, $responseData) { if ($responseLine == Response::RESPONSE_NOT_FOUND) { throw new Exception\ServerException(sprintf( '%s: tube %s does not exist.', $responseLine, $this->_tube )); } elseif ($responseLine == Response::RESPONSE_PAUSED) { return $this->_createResponse(Response::RESPONSE_PAUSED); } else { throw new Exception('Unhandled response: '.$responseLine); } } }