1
|
|
|
<?php |
2
|
|
|
/** |
3
|
|
|
* This file is part of Phiremock. |
4
|
|
|
* |
5
|
|
|
* Phiremock is free software: you can redistribute it and/or modify |
6
|
|
|
* it under the terms of the GNU Lesser General Public License as published by |
7
|
|
|
* the Free Software Foundation, either version 3 of the License, or |
8
|
|
|
* (at your option) any later version. |
9
|
|
|
* |
10
|
|
|
* Phiremock is distributed in the hope that it will be useful, |
11
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
12
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13
|
|
|
* GNU General Public License for more details. |
14
|
|
|
* |
15
|
|
|
* You should have received a copy of the GNU General Public License |
16
|
|
|
* along with Phiremock. If not, see <http://www.gnu.org/licenses/>. |
17
|
|
|
*/ |
18
|
|
|
|
19
|
|
|
namespace Mcustiel\Phiremock\Client\Utils; |
20
|
|
|
|
21
|
|
|
use Mcustiel\Phiremock\Domain\Http\MethodsEnum; |
22
|
|
|
|
23
|
|
|
class A |
24
|
|
|
{ |
25
|
|
|
public static function getRequest(): ConditionsBuilder |
26
|
|
|
{ |
27
|
|
|
return ConditionsBuilder::create(MethodsEnum::GET); |
28
|
|
|
} |
29
|
|
|
|
30
|
|
|
public static function postRequest(): ConditionsBuilder |
31
|
|
|
{ |
32
|
|
|
return ConditionsBuilder::create(MethodsEnum::POST); |
33
|
|
|
} |
34
|
|
|
|
35
|
|
|
public static function putRequest(): ConditionsBuilder |
36
|
|
|
{ |
37
|
|
|
return ConditionsBuilder::create(MethodsEnum::PUT); |
38
|
|
|
} |
39
|
|
|
|
40
|
|
|
public static function optionsRequest(): ConditionsBuilder |
41
|
|
|
{ |
42
|
|
|
return ConditionsBuilder::create(MethodsEnum::OPTIONS); |
43
|
|
|
} |
44
|
|
|
|
45
|
|
|
public static function headRequest(): ConditionsBuilder |
46
|
|
|
{ |
47
|
|
|
return ConditionsBuilder::create(MethodsEnum::HEAD); |
48
|
|
|
} |
49
|
|
|
|
50
|
|
|
public static function fetchRequest(): ConditionsBuilder |
51
|
|
|
{ |
52
|
|
|
return ConditionsBuilder::create(MethodsEnum::FETCH); |
53
|
|
|
} |
54
|
|
|
|
55
|
|
|
public static function deleteRequest(): ConditionsBuilder |
56
|
|
|
{ |
57
|
|
|
return ConditionsBuilder::create(MethodsEnum::DELETE); |
58
|
|
|
} |
59
|
|
|
|
60
|
|
|
public static function patchRequest(): ConditionsBuilder |
61
|
|
|
{ |
62
|
|
|
return ConditionsBuilder::create(MethodsEnum::PATCH); |
63
|
|
|
} |
64
|
|
|
|
65
|
|
|
public static function linkRequest(): ConditionsBuilder |
66
|
|
|
{ |
67
|
|
|
return ConditionsBuilder::create(MethodsEnum::LINK); |
68
|
|
|
} |
69
|
|
|
} |
70
|
|
|
|