Completed
Push — master ( 7582b5...4787fc )
by Park Jong-Hun
03:00
created

Role   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 24
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
1
<?php
2
3
namespace App\Entity;
4
5
use Doctrine\Common\Collections\ArrayCollection;
6
7
/**
8
 * @Entity
9
 * @Table(name="roles")
10
 */
11
class Role
12
{
13
    /**
14
     * @Id
15
     * @Column(type="integer")
16
     * @GeneratedValue
17
     */
18
    protected $id;
19
20
    /**
21
     * @Column(type="string", length=32)
22
     */
23
    protected $name;
24
25
    /**
26
     * @ManyToMany(targetEntity="User", mappedBy="roles")
27
     */
28
    protected $users;
29
30
    public function __construct()
31
    {
32
        $this->users = new ArrayCollection();
33
    }
34
}
35