Ejemplo n.º 1
0
 public function streamPublish($ticket = 1, $exchange = '', $routing_key = '', $mandatory = false, $immediate = false)
 {
     $args = new AMQPWriter();
     $args->write_short($ticket);
     $args->write_shortstr($exchange);
     $args->write_shortstr($routing_key);
     $args->write_bit($mandatory);
     $args->write_bit($immediate);
     return array(80, 40, $args);
 }
Ejemplo n.º 2
0
 protected function x_open($virtual_host, $capabilities = "", $insist = false)
 {
     $args = new AMQPWriter();
     $args->write_shortstr($virtual_host);
     $args->write_shortstr($capabilities);
     $args->write_bit($insist);
     $this->send_method_frame(array(10, 40), $args);
     $wait = array($this->waitHelper->get_wait('connection.open_ok'));
     if ($this->protocolVersion == '0.8') {
         $wait[] = $this->waitHelper->get_wait('connection.redirect');
     }
     return $this->wait($wait);
 }
Ejemplo n.º 3
0
 public function confirmSelect($nowait = false)
 {
     $args = new AMQPWriter();
     $args->write_bit($nowait);
     return array(85, 10, $args);
 }
Ejemplo n.º 4
0
 protected function x_open($virtual_host, $capabilities = "", $insist = false)
 {
     $args = new AMQPWriter();
     $args->write_shortstr($virtual_host);
     $args->write_shortstr($capabilities);
     $args->write_bit($insist);
     $this->send_method_frame(array(10, 40), $args);
     return $this->wait(array("10,41", "10,50"));
 }
Ejemplo n.º 5
0
 public function basicRecover($requeue)
 {
     $args = new AMQPWriter();
     $args->write_bit($requeue);
     return $args;
 }