src/Client.php
public function send($destination, $msg, array $header = [], $sync = null)
    {
        if (!$msg instanceof Frame) {
            return $this->send($destination, new Frame('SEND', $header, $msg), [], $sync);
        }

        $msg->addHeaders($header);
        $msg['destination'] = $destination;
        return $this->sendFrame($msg, $sync);
    }
public function send($destination, $msg, array $header = [], $sync = null)
    {
        if (!$msg instanceof Frame) {
            return $this->send($destination, new Frame('SEND', $header, $msg), [], $sync);
        }

        $msg->addHeaders($header);
        $msg['destination'] = $destination;
        return $this->sendFrame($msg, $sync);
    }
public function send ( $ destination , $ msg , array $ header = [ ] , $ sync = null ) { if ( ! $ msg instanceof Frame ) { return $ this -> send ( $ destination , new Frame ( 'SEND' , $ header , $ msg ) , [ ] , $ sync ) ; } $ msg -> addHeaders ( $ header ) ; $ msg [ 'destination' ] = $ destination ; return $ this -> sendFrame ( $ msg , $ sync ) ; }
Send a message to a destination in the messaging system

@param string $destination Destination queue
@param string|Frame $msg Message
@param array $header
@param boolean $sync Perform request synchronously
@return boolean
Send a message to a destination in the messaging system