chamilo /
chamilo-lms
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
| 1 | <?php |
||
| 2 | /* For licensing terms, see /license.txt */ |
||
| 3 | |||
| 4 | namespace Chamilo\CourseBundle\Entity; |
||
| 5 | |||
| 6 | use Doctrine\ORM\Mapping as ORM; |
||
| 7 | |||
| 8 | /** |
||
| 9 | * CStudentPublicationRelUser |
||
| 10 | * |
||
| 11 | * @ORM\Table( |
||
| 12 | * name="c_student_publication_rel_user", |
||
| 13 | * indexes={ |
||
| 14 | * @ORM\Index(name="course", columns={"c_id"}), |
||
| 15 | * @ORM\Index(name="work", columns={"work_id"}), |
||
| 16 | * @ORM\Index(name="user", columns={"user_id"}) |
||
| 17 | * } |
||
| 18 | * ) |
||
| 19 | * @ORM\Entity |
||
| 20 | */ |
||
| 21 | View Code Duplication | class CStudentPublicationRelUser |
|
|
0 ignored issues
–
show
|
|||
| 22 | { |
||
| 23 | /** |
||
| 24 | * @var integer |
||
| 25 | * |
||
| 26 | * @ORM\Column(name="iid", type="integer") |
||
| 27 | * @ORM\Id |
||
| 28 | * @ORM\GeneratedValue |
||
| 29 | */ |
||
| 30 | private $iid; |
||
|
0 ignored issues
–
show
|
|||
| 31 | |||
| 32 | /** |
||
| 33 | * @var integer |
||
| 34 | * |
||
| 35 | * @ORM\Column(name="id", type="integer", nullable=true) |
||
| 36 | */ |
||
| 37 | private $id; |
||
| 38 | |||
| 39 | /** |
||
| 40 | * @var integer |
||
| 41 | * |
||
| 42 | * @ORM\Column(name="c_id", type="integer") |
||
| 43 | */ |
||
| 44 | private $cId; |
||
| 45 | |||
| 46 | /** |
||
| 47 | * @var integer |
||
| 48 | * |
||
| 49 | * @ORM\Column(name="work_id", type="integer", nullable=false) |
||
| 50 | */ |
||
| 51 | private $workId; |
||
| 52 | |||
| 53 | /** |
||
| 54 | * @var integer |
||
| 55 | * |
||
| 56 | * @ORM\Column(name="user_id", type="integer", nullable=false) |
||
| 57 | */ |
||
| 58 | private $userId; |
||
| 59 | |||
| 60 | /** |
||
| 61 | * Set workId |
||
| 62 | * |
||
| 63 | * @param integer $workId |
||
| 64 | * @return CStudentPublicationRelUser |
||
| 65 | */ |
||
| 66 | public function setWorkId($workId) |
||
| 67 | { |
||
| 68 | $this->workId = $workId; |
||
| 69 | |||
| 70 | return $this; |
||
| 71 | } |
||
| 72 | |||
| 73 | /** |
||
| 74 | * Get workId |
||
| 75 | * |
||
| 76 | * @return integer |
||
| 77 | */ |
||
| 78 | public function getWorkId() |
||
| 79 | { |
||
| 80 | return $this->workId; |
||
| 81 | } |
||
| 82 | |||
| 83 | /** |
||
| 84 | * Set userId |
||
| 85 | * |
||
| 86 | * @param integer $userId |
||
| 87 | * @return CStudentPublicationRelUser |
||
| 88 | */ |
||
| 89 | public function setUserId($userId) |
||
| 90 | { |
||
| 91 | $this->userId = $userId; |
||
| 92 | |||
| 93 | return $this; |
||
| 94 | } |
||
| 95 | |||
| 96 | /** |
||
| 97 | * Get userId |
||
| 98 | * |
||
| 99 | * @return integer |
||
| 100 | */ |
||
| 101 | public function getUserId() |
||
| 102 | { |
||
| 103 | return $this->userId; |
||
| 104 | } |
||
| 105 | |||
| 106 | /** |
||
| 107 | * Set cId |
||
| 108 | * |
||
| 109 | * @param integer $cId |
||
| 110 | * @return CStudentPublicationRelUser |
||
| 111 | */ |
||
| 112 | public function setCId($cId) |
||
| 113 | { |
||
| 114 | $this->cId = $cId; |
||
| 115 | |||
| 116 | return $this; |
||
| 117 | } |
||
| 118 | |||
| 119 | /** |
||
| 120 | * Get cId |
||
| 121 | * |
||
| 122 | * @return integer |
||
| 123 | */ |
||
| 124 | public function getCId() |
||
| 125 | { |
||
| 126 | return $this->cId; |
||
| 127 | } |
||
| 128 | |||
| 129 | /** |
||
| 130 | * Get id |
||
| 131 | * |
||
| 132 | * @return integer |
||
| 133 | */ |
||
| 134 | public function getId() |
||
| 135 | { |
||
| 136 | return $this->id; |
||
| 137 | } |
||
| 138 | } |
||
| 139 |
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.