| 1 | <?php |
||
| 20 | class Target |
||
| 21 | { |
||
| 22 | /** |
||
| 23 | * Controller name as it appears in url |
||
| 24 | * |
||
| 25 | * @var string |
||
| 26 | */ |
||
| 27 | protected $controller; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * Controller action name as it appears in url |
||
| 31 | * |
||
| 32 | * @var string |
||
| 33 | */ |
||
| 34 | protected $action = 'index'; |
||
| 35 | |||
| 36 | /** |
||
| 37 | * List of additional params at teh URL. |
||
| 38 | * |
||
| 39 | * @var array |
||
| 40 | */ |
||
| 41 | protected $params = array(); |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @param string $controller |
||
| 45 | */ |
||
| 46 | public function __construct($controller) |
||
| 50 | |||
| 51 | /** |
||
| 52 | * @param string $action |
||
| 53 | */ |
||
| 54 | public function setAction($action) |
||
| 58 | |||
| 59 | /** |
||
| 60 | * @param array $params |
||
| 61 | */ |
||
| 62 | public function setParams(array $params) |
||
| 66 | |||
| 67 | /** |
||
| 68 | * @return string |
||
| 69 | */ |
||
| 70 | public function getAction() |
||
| 74 | |||
| 75 | /** |
||
| 76 | * Controller-name as it appears in url. |
||
| 77 | * |
||
| 78 | * @return string |
||
| 79 | */ |
||
| 80 | public function getController() |
||
| 84 | |||
| 85 | /** |
||
| 86 | * @return array |
||
| 87 | */ |
||
| 88 | public function getParams() |
||
| 92 | } |
||
| 93 |