1 | <?php |
||
11 | class UrlHelper extends CraftUrlHelper |
||
12 | { |
||
13 | /** |
||
14 | * This is the endpoint used to initiate login. Set the general.php config for `loginPath` to this. |
||
15 | * @see GeneralConfig::$loginPath |
||
16 | * |
||
17 | * @var string |
||
18 | */ |
||
19 | const LOGIN_ENDPOINT = 'login'; |
||
20 | |||
21 | /** |
||
22 | * This is the endpoint used to initiate login. Set the general.php config for `loginPath` to this. |
||
23 | * @see GeneralConfig::$loginPath |
||
24 | * |
||
25 | * @var string |
||
26 | */ |
||
27 | const LOGOUT_ENDPOINT = 'logout'; |
||
28 | |||
29 | /** |
||
30 | * This is the endpoint used to initiate login. Set the general.php config for `loginPath` to this. |
||
31 | * @see GeneralConfig::$loginPath |
||
32 | * |
||
33 | * @var string |
||
34 | */ |
||
35 | const LOGIN_REQUEST_ENDPOINT = 'login/request'; |
||
36 | |||
37 | /** |
||
38 | * This is the endpoint used to initiate logout. In this case, `logoutPath` cannot be used. |
||
39 | * Point your logout button to this endpoint. |
||
40 | * |
||
41 | * @var string |
||
42 | */ |
||
43 | const LOGOUT_REQUEST_ENDPOINT = 'logout/request'; |
||
44 | |||
45 | /** |
||
46 | * @param AbstractSettings $settings |
||
47 | * @param string $endpoint |
||
48 | * @return string |
||
49 | */ |
||
50 | public static function buildEndpointPath(AbstractSettings $settings, string $endpoint) |
||
54 | |||
55 | /** |
||
56 | * @param string $baseUrl |
||
57 | * @return string |
||
58 | */ |
||
59 | protected static function providerBaseUrl(string $baseUrl) |
||
78 | |||
79 | /** |
||
80 | * @param AbstractSettings $settings |
||
81 | * @param string $endpoint |
||
82 | * @param AbstractProvider $provider |
||
83 | * @param bool $fullUrl |
||
84 | * @return string |
||
85 | * @throws \yii\base\Exception |
||
86 | */ |
||
87 | public static function buildEndpointUrl(AbstractSettings $settings, string $endpoint, AbstractProvider $provider, $fullUrl = true) |
||
104 | } |
||
105 |
Since your code implements the magic setter
_set
, this function will be called for any write access on an undefined variable. You can add the@property
annotation to your class or interface to document the existence of this variable.Since the property has write access only, you can use the @property-write annotation instead.
Of course, you may also just have mistyped another name, in which case you should fix the error.
See also the PhpDoc documentation for @property.