| 1 | <?php |
||
| 5 | class PermissionParameter |
||
| 6 | { |
||
| 7 | /** |
||
| 8 | * Name of ID column, will default to 'id'. |
||
| 9 | * |
||
| 10 | * @var string |
||
| 11 | */ |
||
| 12 | private $column; |
||
| 13 | |||
| 14 | /** |
||
| 15 | * Name of the permission. |
||
| 16 | * |
||
| 17 | * @var string |
||
| 18 | */ |
||
| 19 | private $name; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Create a new PermissionParameter instance. |
||
| 23 | * |
||
| 24 | * PermissionParameter constructor. |
||
| 25 | * @param $input |
||
| 26 | */ |
||
| 27 | public function __construct($input) |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Get the permission name. |
||
| 36 | * |
||
| 37 | * @return string |
||
| 38 | */ |
||
| 39 | public function getName() |
||
| 43 | |||
| 44 | /** |
||
| 45 | * Get the column name. |
||
| 46 | * |
||
| 47 | * @return string |
||
| 48 | */ |
||
| 49 | public function getColumn() |
||
| 53 | |||
| 54 | /** |
||
| 55 | * Instantiate the instance with a column name 'id'. |
||
| 56 | * |
||
| 57 | * @param $permission |
||
| 58 | */ |
||
| 59 | private function withDefaultID($permission) |
||
| 64 | |||
| 65 | /** |
||
| 66 | * Instantiate the instance with a custom column name. |
||
| 67 | * |
||
| 68 | * @param array $args |
||
| 69 | */ |
||
| 70 | private function withCustomID(array $args) |
||
| 75 | } |