| Total Complexity | 5 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 22 | class EventRepository extends AbstractRepository implements EventRepositoryInterface |
||
| 23 | { |
||
| 24 | public function eventRead(int $eventId): void |
||
| 25 | { |
||
| 26 | $this->client->post(sprintf('%s/%s/read', $this->getBaseUri(), $eventId)); |
||
| 27 | } |
||
| 28 | |||
| 29 | public function eventSeen(int $eventId): void |
||
| 30 | { |
||
| 31 | $this->client->post(sprintf('%s/%s/seen', $this->getBaseUri(), $eventId)); |
||
| 32 | } |
||
| 33 | |||
| 34 | protected function getBaseUri(): string |
||
| 37 | } |
||
| 38 | |||
| 39 | protected function getSupportedFields(): array |
||
| 40 | { |
||
| 41 | return [ |
||
| 42 | Event::FIELD_ID, |
||
| 43 | Event::FIELD_USERNAME, |
||
| 44 | Event::FIELD_ACTION, |
||
| 45 | Event::FIELD_ENTITY, |
||
| 46 | Event::FIELD_CREATED, |
||
| 47 | Event::FIELD_STATUS, |
||
| 48 | Event::FIELD_SEEN, |
||
| 49 | Event::FIELD_READ, |
||
| 50 | Event::FIELD_RATE, |
||
| 51 | Event::FIELD_PERCENT_COMPLETE, |
||
| 52 | Event::FIELD_TIME_REMAINING, |
||
| 53 | ]; |
||
| 54 | } |
||
| 55 | |||
| 56 | protected function jsonToEntity(array $json): Entity |
||
| 59 | } |
||
| 60 | } |
||
| 61 |