X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=extlib%2FStomp%2FMessage%2FMap.php;h=38a32c56c4da7918b4e19becd18eb7447c6e6cc1;hb=014a32e6b873291bcd289a1ed25759a7a29221d7;hp=288456a8490d8704dba260f25c108fc396dc0355;hpb=c9c5ec0e4beea45d6257a263e5e0f0d4e6c57025;p=quix0rs-gnu-social.git diff --git a/extlib/Stomp/Message/Map.php b/extlib/Stomp/Message/Map.php index 288456a849..38a32c56c4 100644 --- a/extlib/Stomp/Message/Map.php +++ b/extlib/Stomp/Message/Map.php @@ -24,30 +24,28 @@ require_once 'Stomp/Message.php'; * Message that contains a set of name-value pairs * * @package Stomp - * @author Dejan Bosanac - * @version $Revision: 23 $ */ -class Stomp_Message_Map extends Stomp_Message +class StompMessageMap extends StompMessage { public $map; /** * Constructor * - * @param Stomp_Frame|string $msg + * @param StompFrame|string $msg * @param array $headers */ function __construct ($msg, $headers = null) { - if ($msg instanceof Stomp_Frame) { + if ($msg instanceof StompFrame) { $this->_init($msg->command, $msg->headers, $msg->body); - $this->map = json_decode($msg->body); + $this->map = json_decode($msg->body, true); } else { $this->_init("SEND", $headers, $msg); if ($this->headers == null) { $this->headers = array(); } - $this->headers['amq-msg-type'] = 'MapMessage'; + $this->headers['transformation'] = 'jms-map-json'; $this->body = json_encode($msg); } }