for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace League\Tactician\Handler\MethodNameInflector;
/**
* Assumes the method is handle + the last portion of the class name.
*
* Examples:
* - \MyGlobalCommand => $handler->handleMyGlobalCommand()
* - \My\App\TaskCompletedCommand => $handler->handleTaskCompletedCommand()
*/
class HandleClassNameInflector extends ClassNameInflector
{
* {@inheritdoc}
public function inflect($command, $commandHandler): string
$commandName = parent::inflect($command, $commandHandler);
return 'handle' . ucfirst($commandName);
}