1 | <?php |
||
27 | trait Match |
||
28 | { |
||
29 | use ResultEntity; |
||
30 | |||
31 | //<editor-fold desc="Fields"> |
||
32 | |||
33 | /** |
||
34 | * @ORM\ManyToOne(targetEntity="\Tfboe\FmLib\Entity\PhaseInterface", inversedBy="matches") |
||
35 | * @var PhaseInterface |
||
36 | */ |
||
37 | private $phase; |
||
38 | |||
39 | /** |
||
40 | * @ORM\ManyToMany(targetEntity="\Tfboe\FmLib\Entity\Ranking", indexBy="uniqueRank") |
||
41 | * @ORM\JoinTable(name="relation__match_rankingA") |
||
42 | * @var Collection|Ranking |
||
43 | */ |
||
44 | private $rankingsA; |
||
45 | |||
46 | /** |
||
47 | * @ORM\ManyToMany(targetEntity="\Tfboe\FmLib\Entity\Ranking", indexBy="uniqueRank") |
||
48 | * @ORM\JoinTable(name="relation__match_rankingB") |
||
49 | * @var Collection|Ranking |
||
50 | */ |
||
51 | private $rankingsB; |
||
52 | |||
53 | /** |
||
54 | * @ORM\Column(type="integer") |
||
55 | * @var int |
||
56 | */ |
||
57 | private $matchNumber; |
||
58 | |||
59 | /** |
||
60 | * @ORM\OneToMany(targetEntity="\Tfboe\FmLib\Entity\GameInterface", mappedBy="match", indexBy="gameNumber") |
||
61 | * @var Collection|GameInterface[] |
||
62 | */ |
||
63 | private $games; |
||
64 | //</editor-fold desc="Fields"> |
||
65 | |||
66 | //<editor-fold desc="Public Methods"> |
||
67 | /** |
||
68 | * @inheritDoc |
||
69 | */ |
||
70 | public function getChildren(): Collection |
||
74 | |||
75 | /** |
||
76 | * @return GameInterface[]|Collection |
||
77 | */ |
||
78 | public function getGames() |
||
82 | |||
83 | /** |
||
84 | * @inheritDoc |
||
85 | */ |
||
86 | public function getLevel(): int |
||
90 | |||
91 | /** |
||
92 | * @inheritDoc |
||
93 | */ |
||
94 | public function getLocalIdentifier() |
||
98 | |||
99 | /** |
||
100 | * @return int |
||
101 | */ |
||
102 | public function getMatchNumber(): int |
||
106 | |||
107 | /** |
||
108 | * @inheritDoc |
||
109 | */ |
||
110 | public function getParent(): ?TournamentHierarchyInterface |
||
114 | |||
115 | /** |
||
116 | * @return PhaseInterface |
||
117 | */ |
||
118 | public function getPhase(): PhaseInterface |
||
122 | |||
123 | /** |
||
124 | * @return Ranking|Collection |
||
125 | */ |
||
126 | public function getRankingsA() |
||
130 | |||
131 | /** |
||
132 | * @return Ranking|Collection |
||
133 | */ |
||
134 | public function getRankingsB() |
||
138 | |||
139 | /** |
||
140 | * Match constructor. |
||
141 | */ |
||
142 | public function init() |
||
148 | |||
149 | /** |
||
150 | * @param int $matchNumber |
||
151 | */ |
||
152 | public function setMatchNumber(int $matchNumber) |
||
156 | |||
157 | /** |
||
158 | * @param PhaseInterface $phase |
||
159 | */ |
||
160 | public function setPhase(PhaseInterface $phase) |
||
168 | //</editor-fold desc="Public Methods"> |
||
169 | } |