| @@ 64-70 (lines=7) @@ | ||
| 61 | * @throws \InvalidArgumentException if the label is invalid |
|
| 62 | * @since 8.2.0 |
|
| 63 | */ |
|
| 64 | public function setLabel($label) { |
|
| 65 | if (!is_string($label) || $label === '' || isset($label[32])) { |
|
| 66 | throw new \InvalidArgumentException('The given label is invalid'); |
|
| 67 | } |
|
| 68 | $this->label = $label; |
|
| 69 | return $this; |
|
| 70 | } |
|
| 71 | ||
| 72 | /** |
|
| 73 | * @return string |
|
| @@ 109-115 (lines=7) @@ | ||
| 106 | * @throws \InvalidArgumentException if the app id is invalid |
|
| 107 | * @since 8.2.0 |
|
| 108 | */ |
|
| 109 | public function setApp($app) { |
|
| 110 | if (!is_string($app) || $app === '' || isset($app[32])) { |
|
| 111 | throw new \InvalidArgumentException('The given app name is invalid'); |
|
| 112 | } |
|
| 113 | $this->app = $app; |
|
| 114 | return $this; |
|
| 115 | } |
|
| 116 | ||
| 117 | /** |
|
| 118 | * @return string |
|
| @@ 131-137 (lines=7) @@ | ||
| 128 | * @throws \InvalidArgumentException if the user id is invalid |
|
| 129 | * @since 8.2.0 |
|
| 130 | */ |
|
| 131 | public function setUser($user) { |
|
| 132 | if (!is_string($user) || $user === '' || isset($user[64])) { |
|
| 133 | throw new \InvalidArgumentException('The given user id is invalid'); |
|
| 134 | } |
|
| 135 | $this->user = $user; |
|
| 136 | return $this; |
|
| 137 | } |
|
| 138 | ||
| 139 | /** |
|
| 140 | * @return string |
|
| @@ 327-333 (lines=7) @@ | ||
| 324 | * @throws \InvalidArgumentException if the link are invalid |
|
| 325 | * @since 8.2.0 |
|
| 326 | */ |
|
| 327 | public function setLink($link) { |
|
| 328 | if (!is_string($link) || $link === '' || isset($link[4000])) { |
|
| 329 | throw new \InvalidArgumentException('The given link is invalid'); |
|
| 330 | } |
|
| 331 | $this->link = $link; |
|
| 332 | return $this; |
|
| 333 | } |
|
| 334 | ||
| 335 | /** |
|
| 336 | * @return string |
|