@@ 172-180 (lines=9) @@ | ||
169 | continue; |
|
170 | } |
|
171 | ||
172 | if ($dataType === self::EVENT_TYPE_TEXT) { |
|
173 | // trigger MESSAGE event |
|
174 | try { |
|
175 | echo 'trigger MESSAGE event'; |
|
176 | $this->handler->onMessage($this->cureentConn, $dataPayload); |
|
177 | } catch (WebSocketException $e) { |
|
178 | $e->printStack(); |
|
179 | } |
|
180 | } |
|
181 | ||
182 | if ($dataType === self::EVENT_TYPE_PING) { |
|
183 | // trigger PING event |
|
@@ 182-189 (lines=8) @@ | ||
179 | } |
|
180 | } |
|
181 | ||
182 | if ($dataType === self::EVENT_TYPE_PING) { |
|
183 | // trigger PING event |
|
184 | try { |
|
185 | $this->handler->onPing($this->cureentConn, $dataPayload); |
|
186 | } catch (WebSocketException $e) { |
|
187 | $e->printStack(); |
|
188 | } |
|
189 | } |
|
190 | ||
191 | if ($dataType === self::EVENT_TYPE_PONG) { |
|
192 | // trigger PONG event |
|
@@ 191-198 (lines=8) @@ | ||
188 | } |
|
189 | } |
|
190 | ||
191 | if ($dataType === self::EVENT_TYPE_PONG) { |
|
192 | // trigger PONG event |
|
193 | try { |
|
194 | $this->handler->onPong($this->cureentConn, $dataPayload); |
|
195 | } catch (WebSocketException $e) { |
|
196 | $e->printStack(); |
|
197 | } |
|
198 | } |
|
199 | } |
|
200 | } |
|
201 | } |