Пример #1
0
 public function __construct(MessageEvent $event, ChatRoom $room)
 {
     $this->event = $event;
     $this->room = $room;
     $this->type = self::$eventTypeMap[$event->getTypeId()];
 }
Пример #2
0
 private function isCommandMessage(MessageEvent $event)
 {
     return strpos($event->getMessageContent()->textContent, '!!') === 0;
 }
Пример #3
0
 public function __construct(array $data, ChatRoom $room)
 {
     parent::__construct($data, $room);
     $this->numberOfEdits = (int) $data['message_edits'];
 }