FSM
FSM copied to clipboard
Use __construct() constructor
I namespaced fsm.php into my own application library, and bumped into a constructor issue.
new lib\FSM('START', $this->payload); doesn't actually set initialstate and currentstate,
because the FSM() method is not seen as a constructor.
Maybe it is time to start php 5.0 compatibility and use __construct() :-)
I'd accept a pull request that moves this package to PHP 5+.
We should probably move to PSR4. This means rewriting examples, tests and documentation as well.