| 1 | <?php |
||
| 12 | class Permission implements PermissionInterface |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var int|null |
||
| 16 | * |
||
| 17 | * @ORM\Id |
||
| 18 | * @ORM\Column(type="integer") |
||
| 19 | * @ORM\GeneratedValue(strategy="AUTO") |
||
| 20 | */ |
||
| 21 | protected $id; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var string|null |
||
| 25 | * |
||
| 26 | * @ORM\Column(type="string", length=128, unique=true) |
||
| 27 | */ |
||
| 28 | protected $name; |
||
| 29 | |||
| 30 | /** |
||
| 31 | * Constructor |
||
| 32 | */ |
||
| 33 | public function __construct($name) |
||
| 37 | |||
| 38 | /** |
||
| 39 | * Get the permission identifier |
||
| 40 | * |
||
| 41 | * @return int |
||
| 42 | */ |
||
| 43 | public function getId() |
||
| 47 | |||
| 48 | /** |
||
| 49 | * {@inheritDoc} |
||
| 50 | */ |
||
| 51 | public function __toString() |
||
| 55 | } |
||
| 56 |