| Total Complexity | 6 |
| Total Lines | 68 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | class PollAnswer |
||
| 15 | { |
||
| 16 | |||
| 17 | /** |
||
| 18 | * Unique poll identifier |
||
| 19 | * |
||
| 20 | * @var string |
||
| 21 | */ |
||
| 22 | private $poll_id; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * The user, who changed the answer to the poll |
||
| 26 | * |
||
| 27 | * @var User |
||
| 28 | */ |
||
| 29 | private $user; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @var int[] |
||
| 33 | */ |
||
| 34 | private $option_ids; |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @return string |
||
| 38 | */ |
||
| 39 | public function getPollId(): string |
||
| 40 | { |
||
| 41 | return $this->poll_id; |
||
| 42 | } |
||
| 43 | |||
| 44 | /** |
||
| 45 | * @param string $poll_id |
||
| 46 | */ |
||
| 47 | public function setPollId(string $poll_id): void |
||
| 48 | { |
||
| 49 | $this->poll_id = $poll_id; |
||
| 50 | } |
||
| 51 | |||
| 52 | /** |
||
| 53 | * @return User |
||
| 54 | */ |
||
| 55 | public function getUser(): User |
||
| 56 | { |
||
| 57 | return $this->user; |
||
| 58 | } |
||
| 59 | |||
| 60 | /** |
||
| 61 | * @param User $user |
||
| 62 | */ |
||
| 63 | public function setUser(User $user): void |
||
| 64 | { |
||
| 65 | $this->user = $user; |
||
| 66 | } |
||
| 67 | |||
| 68 | /** |
||
| 69 | * @return int[] |
||
| 70 | */ |
||
| 71 | public function getOptionIds(): array |
||
| 72 | { |
||
| 73 | return $this->option_ids; |
||
| 74 | } |
||
| 75 | |||
| 76 | /** |
||
| 77 | * @param int[] $option_ids |
||
| 78 | */ |
||
| 79 | public function setOptionIds(array $option_ids): void |
||
| 82 | } |
||
| 83 | |||
| 84 | } |