コード例 #1
0
ファイル: Queue.php プロジェクト: alexeytihomirov/epic-queue
 public function __construct(Client $client)
 {
     $this->client = $client;
     $self = $this;
     $client->connect()->then(function () use($self) {
         $self->applySubscriptions();
     });
 }
コード例 #2
0
ファイル: ClientTest.php プロジェクト: romainneutron/stomp
 private function getConnectedClient(InputStreamInterface $input, OutputStreamInterface $output)
 {
     $client = new Client($input, $output, array('vhost' => 'localhost'));
     $client->connect();
     $input->emit('frame', array(new Frame('CONNECTED')));
     return $client;
 }