1 | <?php |
||
16 | class UnicomponentTest extends TestCase |
||
17 | { |
||
18 | /** |
||
19 | * Method description:Test Register Component. |
||
20 | * |
||
21 | * @author reallyli <[email protected]> |
||
22 | * @since 18/10/11 |
||
23 | * @return mixed |
||
24 | * 返回值类型:string,array,object,mixed(多种,不确定的),void(无返回值) |
||
25 | */ |
||
26 | public function testRegisterComponent() |
||
34 | |||
35 | /** |
||
36 | * Method description:testConfigurationComponents. |
||
37 | * |
||
38 | * @author reallyli <[email protected]> |
||
39 | * @since 18/10/11 |
||
40 | * @return mixed |
||
41 | * 返回值类型:string,array,object,mixed(多种,不确定的),void(无返回值) |
||
42 | */ |
||
43 | public function testConfigurationComponents() |
||
50 | |||
51 | /** |
||
52 | * Method description:Test Get Component. |
||
53 | * |
||
54 | * @author reallyli <[email protected]> |
||
55 | * @since 18/10/11 |
||
56 | * @return mixed |
||
57 | * 返回值类型:string,array,object,mixed(多种,不确定的),void(无返回值) |
||
58 | */ |
||
59 | public function testGetComponent() |
||
67 | } |
||
68 |
If you implement
__call
and you know which methods are available, you can improve IDE auto-completion and static analysis by adding a @method annotation to the class.This is often the case, when
__call
is implemented by a parent class and only the child class knows which methods exist: