forked from zircote/swagger-php
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathProductController.php
75 lines (66 loc) · 1.68 KB
/
ProductController.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<?php
namespace UsingRefs;
/**
* @OA\PathItem(
* path="/products/{product_id}",
* @OA\Parameter(ref="#/components/parameters/product_id_in_path_required")
* )
*/
class ProductController {
/**
* @OA\Get(
* tags={"Products"},
* path="/products/{product_id}",
* @OA\Response(
* response="default",
* description="successful operation",
* @OA\MediaType(
* mediaType="application/json",
* @OA\Schema(
* ref="#/components/responses/product"
* )
* )
* )
* )
*/
public function getProduct($id) {
}
/**
* @OA\Patch(
* tags={"Products"},
* path="/products/{product_id}",
* @OA\Parameter(ref="#/components/requestBodies/product_in_body"),
* @OA\Response(
* response="default",
* description="successful operation",
* @OA\MediaType(
* mediaType="application/json",
* @OA\Schema(
* ref="#/components/responses/product"
* )
* )
* )
* )
*/
public function updateProduct($id) {
}
/**
* @OA\Post(
* tags={"Products"},
* path="/products",
* @OA\Parameter(ref="#/components/requestBodies/product_in_body"),
* @OA\Response(
* response="default",
* description="successful operation",
* @OA\MediaType(
* mediaType="application/json",
* @OA\Schema(
* ref="#/components/responses/product"
* )
* )
* )
* )
*/
public function addProduct($id) {
}
}