Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- namespace models;
- /**
- * @Entity
- * @Table(name="clubs_matches")
- */
- class ClubsMatches {
- /**
- * @Id
- * @Column(type="integer", nullable=false)
- * @GeneratedValue(strategy="AUTO")
- */
- protected $id;
- /**
- * @ManyToOne(targetEntitiy="Matches", inversedBy="clubsmatches")
- * @JoinColumn(name="match_id", referencedColumnName="id")
- * @Column(type="integer", nullable=false)
- */
- protected $match_id;
- /**
- * @ManyToOne(targetEntitiy="Clubs", inversedBy="clubsmatches")
- * @JoinColumn(name="club_id", referencedColumnName="id")
- * @Column(type="integer", nullable=false)
- */
- protected $club_id;
- /**
- * @Column(type="integer", length="3", nullable=false)
- */
- protected $score;
- /**
- * @Column(type="integer", length="1", nullable=false)
- */
- protected $is_home;
- // GETTERS & SETTERS
- public function setMatch_id($id) {
- $this->match_id = $id;
- }
- public function getMatch_id() {
- return $this->match_id;
- }
- public function setClub_id($id) {
- $this->club_id = $id;
- }
- public function getClub_id() {
- return $this->club_id;
- }
- public function setScore($score) {
- $this->score = $score;
- }
- public function getScore() {
- return $this->score;
- }
- public function setIs_home($is_home) {
- $this->is_home = $is_home;
- }
- public function getIs_home() {
- return $this->is_home;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement