1 | <?php |
||
7 | class Producer extends Stomp implements ProducerInterface |
||
8 | { |
||
9 | protected $debug = false; |
||
10 | protected $contentType = 'text/plain'; |
||
11 | |||
12 | /** |
||
13 | * @param string $contentType |
||
14 | * @return Producer |
||
15 | * @throws \Exception if unsupported contentType is used |
||
16 | */ |
||
17 | public function setContentType($contentType) |
||
23 | |||
24 | /** |
||
25 | * Publishes the message |
||
26 | * |
||
27 | * @param string $msgBody |
||
28 | * @param string $routingKey |
||
29 | * @param array $additionalProperties |
||
30 | * |
||
31 | * @todo support custom message attributes |
||
32 | */ |
||
33 | public function publish($msgBody, $routingKey = '', $additionalProperties = array()) |
||
46 | |||
47 | /** |
||
48 | * @param array $messages |
||
49 | */ |
||
50 | public function batchPublish(array $messages) |
||
66 | |||
67 | /** |
||
68 | * Prepares the extra headers to be injected into the requests |
||
69 | * @param array $additionalProperties |
||
70 | * @return array |
||
71 | */ |
||
72 | protected function getClientProperties(array $additionalProperties = array()) |
||
78 | |||
79 | } |
||
80 |