@@ -212,9 +212,6 @@ discard block |
||
212 | 212 | * Command with the domain object injected. |
213 | 213 | * |
214 | 214 | * @param Context $context |
215 | - * @param string $event |
|
216 | - * optional in case the transition was triggered by an event code |
|
217 | - * (mealy machine) |
|
218 | 215 | * @return void |
219 | 216 | */ |
220 | 217 | public function process(Context $context) |
@@ -235,7 +232,6 @@ discard block |
||
235 | 232 | * calls the $callable as part of the transition |
236 | 233 | * @param callable $callable |
237 | 234 | * @param Context $context |
238 | - * @param string $event |
|
239 | 235 | */ |
240 | 236 | protected function callCallable($callable, Context $context) { |
241 | 237 | //in case it is a guard callable we need to return true/false |
@@ -360,6 +356,9 @@ discard block |
||
360 | 356 | return $this->command; |
361 | 357 | } |
362 | 358 | |
359 | + /** |
|
360 | + * @param string $command |
|
361 | + */ |
|
363 | 362 | public function setCommandName($command) |
364 | 363 | { |
365 | 364 | $this->command = trim($command); |
@@ -371,6 +370,9 @@ discard block |
||
371 | 370 | return $this->rule; |
372 | 371 | } |
373 | 372 | |
373 | + /** |
|
374 | + * @param string $rule |
|
375 | + */ |
|
374 | 376 | public function setRuleName($rule) |
375 | 377 | { |
376 | 378 | $this->rule = trim($rule); |
@@ -70,6 +70,9 @@ discard block |
||
70 | 70 | return $output; |
71 | 71 | } |
72 | 72 | |
73 | + /** |
|
74 | + * @param string $string |
|
75 | + */ |
|
73 | 76 | private static function escape($string) |
74 | 77 | { |
75 | 78 | $string = addslashes($string); |
@@ -79,7 +82,7 @@ discard block |
||
79 | 82 | /** |
80 | 83 | * creates plantuml state output for a statemachine |
81 | 84 | * |
82 | - * @param string $machine |
|
85 | + * @param StateMachine $machine |
|
83 | 86 | * @return string plant uml code, this can be used to render an image |
84 | 87 | * @link http://www.plantuml.com/plantuml/ |
85 | 88 | * @link http://plantuml.sourceforge.net/state.html |
@@ -1,8 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | namespace izzum\statemachine\utils; |
3 | 3 | use izzum\statemachine\StateMachine; |
4 | -use izzum\statemachine\Transition; |
|
5 | -use izzum\statemachine\State; |
|
6 | 4 | use izzum\statemachine\Exception; |
7 | 5 | |
8 | 6 | /** |
@@ -4,10 +4,8 @@ |
||
4 | 4 | use izzum\statemachine\loader\Loader; |
5 | 5 | use izzum\statemachine\Identifier; |
6 | 6 | use izzum\statemachine\Exception; |
7 | -use izzum\statemachine\State; |
|
8 | 7 | use izzum\statemachine\Transition; |
9 | 8 | use izzum\statemachine\StateMachine; |
10 | -use izzum\statemachine\utils\Utils; |
|
11 | 9 | |
12 | 10 | /** |
13 | 11 | * mix and match a loader (reader) and a persistance adapter (writer) by wrapping |
@@ -6,7 +6,6 @@ |
||
6 | 6 | use izzum\statemachine\Context; |
7 | 7 | use izzum\command\ICommand; |
8 | 8 | use izzum\statemachine\State; |
9 | -use izzum\statemachine\StateMachine; |
|
10 | 9 | |
11 | 10 | /** |
12 | 11 | * utils class that has some helper methods for diverse purposes |