1 | <?php |
||
34 | Class Config extends MagicAttributes |
||
35 | { |
||
36 | /** |
||
37 | * 构造方法初始化参数 |
||
38 | * |
||
39 | * @param null $appId |
||
40 | * @param null $appSecret |
||
41 | * @param bool|false $debug |
||
42 | */ |
||
43 | public function __construct($appId,$appSecret = null,$debug = false) |
||
52 | |||
53 | /** |
||
54 | * 设置消息参数 |
||
55 | * |
||
56 | * @param null $token |
||
57 | * @param null $encodingAESKey |
||
58 | */ |
||
59 | public function setMessageConfig($token,$encodingAESKey = null) |
||
65 | |||
66 | /** |
||
67 | * 设置支付参数 |
||
68 | * |
||
69 | * @param null $mchId |
||
70 | * @param null $mchKey |
||
71 | */ |
||
72 | public function setPayConfig($mchId, $mchKey) |
||
78 | |||
79 | /** |
||
80 | * 设置证书 |
||
81 | * |
||
82 | * @param null $clientCert |
||
83 | * @param null $clientKey |
||
84 | */ |
||
85 | public function setPEMConfig($clientCert, $clientKey) |
||
90 | |||
91 | public function __get($property) |
||
96 | } |
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.