| 1 | <?php |
||
| 5 | class Icon extends AbstractAction |
||
| 6 | { |
||
| 7 | protected $iconClass; |
||
| 8 | |||
| 9 | protected $iconLink; |
||
| 10 | |||
| 11 | /** |
||
| 12 | * Set the icon class (CSS) |
||
| 13 | * - used for HTML if provided, overwise the iconLink is used. |
||
| 14 | * |
||
| 15 | * @param string $name |
||
| 16 | */ |
||
| 17 | public function setIconClass($name) |
||
| 18 | { |
||
| 19 | $this->iconClass = (string) $name; |
||
| 20 | } |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @return string |
||
| 24 | */ |
||
| 25 | public function getIconClass() |
||
| 29 | |||
| 30 | /** |
||
| 31 | * @return bool |
||
| 32 | */ |
||
| 33 | public function hasIconClass() |
||
| 41 | |||
| 42 | /** |
||
| 43 | * Set the icon link (is used, if no icon class is provided). |
||
| 44 | * |
||
| 45 | * @param string $httpLink |
||
| 46 | */ |
||
| 47 | public function setIconLink($httpLink) |
||
| 51 | |||
| 52 | /** |
||
| 53 | * Get the icon link. |
||
| 54 | * |
||
| 55 | * @return string |
||
| 56 | */ |
||
| 57 | public function getIconLink() |
||
| 61 | |||
| 62 | /** |
||
| 63 | * @return bool |
||
| 64 | */ |
||
| 65 | public function hasIconLink() |
||
| 73 | |||
| 74 | /** |
||
| 75 | * @return string |
||
| 76 | */ |
||
| 77 | protected function getHtmlType() |
||
| 89 | } |
||
| 90 |