1 | <?php |
||
11 | class DeviceController extends ApiController |
||
12 | { |
||
13 | /** |
||
14 | * @var DeviceTransformer |
||
15 | */ |
||
16 | private $transformer; |
||
17 | |||
18 | 9 | public function __construct(DeviceTransformer $transformer) |
|
24 | |||
25 | /** |
||
26 | * Display a listing of the resource. |
||
27 | * |
||
28 | * @param null $group |
||
29 | * |
||
30 | * @return Response |
||
31 | */ |
||
32 | 1 | public function index($group = null) |
|
41 | |||
42 | /** |
||
43 | * Store a newly created resource in storage. |
||
44 | * |
||
45 | * @param StoreComputerRequest $request |
||
46 | * |
||
47 | * @return Response |
||
48 | */ |
||
49 | 1 | public function store(StoreComputerRequest $request) |
|
57 | |||
58 | /** |
||
59 | * Display the specified resource. |
||
60 | * |
||
61 | * @param int $id |
||
62 | * |
||
63 | * @return Response |
||
64 | */ |
||
65 | 1 | public function show($id) |
|
77 | |||
78 | /** |
||
79 | * Update the specified resource in storage. |
||
80 | * |
||
81 | * @param StoreComputerRequest $request |
||
82 | * @param int $id |
||
83 | * |
||
84 | * @return Response |
||
85 | */ |
||
86 | 1 | public function update(StoreComputerRequest $request, $id) |
|
102 | |||
103 | /** |
||
104 | * Remove the specified resource from storage. |
||
105 | * |
||
106 | * @param int $id |
||
107 | * |
||
108 | * @return Response |
||
109 | */ |
||
110 | 1 | public function destroy($id) |
|
122 | |||
123 | /** |
||
124 | * Handle device pokes. |
||
125 | * |
||
126 | * @param StoreComputerRequest $request |
||
127 | * |
||
128 | * @throws \Exception |
||
129 | * |
||
130 | * @return Response |
||
131 | */ |
||
132 | 4 | public function poke(StoreComputerRequest $request) |
|
147 | } |
||
148 |
Since your code implements the magic getter
_get
, this function will be called for any read access on an undefined variable. You can add the@property
annotation to your class or interface to document the existence of this variable.If the property has read access only, you can use the @property-read 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.