示例#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'];
 }