1 | <?php |
||
10 | class Execution |
||
11 | { |
||
12 | /** |
||
13 | * @var Client |
||
14 | */ |
||
15 | private $client; |
||
16 | |||
17 | /** |
||
18 | * @param Client $client |
||
19 | */ |
||
20 | public function __construct(Client $client) |
||
24 | |||
25 | /** |
||
26 | * @param string $id |
||
27 | * @return PromiseInterface |
||
28 | */ |
||
29 | public function info(string $id): PromiseInterface |
||
35 | |||
36 | /** |
||
37 | * @param string $id |
||
38 | * @return PromiseInterface |
||
39 | */ |
||
40 | public function delete(string $id): PromiseInterface |
||
46 | |||
47 | /** |
||
48 | * @param int[] $ids |
||
49 | * @return PromiseInterface |
||
50 | */ |
||
51 | public function bulkDelete(array $ids): PromiseInterface |
||
57 | |||
58 | /** |
||
59 | * @param string $id |
||
60 | * @return PromiseInterface |
||
61 | */ |
||
62 | public function state(string $id): PromiseInterface |
||
68 | |||
69 | /** |
||
70 | * @param string $id |
||
71 | * @param string|null $node |
||
72 | * @param string|null $step |
||
73 | * @param array $params |
||
74 | * @return PromiseInterface |
||
75 | */ |
||
76 | public function output(string $id, string $node = null, string $step = null, array $params = []): PromiseInterface |
||
92 | |||
93 | /** |
||
94 | * @param string $id |
||
95 | * @param bool $stateOnly |
||
96 | * @return PromiseInterface |
||
97 | */ |
||
98 | public function outputWithState(string $id, bool $stateOnly = false): PromiseInterface |
||
104 | |||
105 | /** |
||
106 | * @param string $id |
||
107 | * @param array $params |
||
108 | * @return PromiseInterface |
||
109 | */ |
||
110 | public function abort(string $id, array $params = []): PromiseInterface |
||
120 | |||
121 | /** |
||
122 | * @return PromiseInterface |
||
123 | */ |
||
124 | public function enable(): PromiseInterface |
||
130 | |||
131 | /** |
||
132 | * @return PromiseInterface |
||
133 | */ |
||
134 | public function disable(): PromiseInterface |
||
140 | } |
||
141 |
In PHP, under loose comparison (like
==
, or!=
, orswitch
conditions), values of different types might be equal.For
string
values, the empty string''
is a special case, in particular the following results might be unexpected: