for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Tleckie\DesignPatterns\State;
use Exception;
/**
* Class State
*
* @package Tleckie\DesignPatterns\State
* @author Teodoro Leckie Westberg <[email protected]>
*/
class State implements CarState
{
* @return SpeedUpState
* @throws Exception
public function speedUp(): SpeedUpState
throw new Exception();
}
* @return BrakeState
public function brake(): BrakeState
* @return OffState
public function turnOff(): OffState
* @return OnState
public function turnOn(): OnState