Chris@0: Chris@0: * Chris@0: * For the full copyright and license information, please view the LICENSE Chris@0: * file that was distributed with this source code. Chris@0: */ Chris@0: Chris@0: namespace Behat\Mink\Exception; Chris@0: Chris@0: use Behat\Mink\Driver\DriverInterface; Chris@0: Chris@0: /** Chris@0: * Exception thrown by drivers when they don't support the requested action. Chris@0: * Chris@0: * @author Konstantin Kudryashov Chris@0: */ Chris@0: class UnsupportedDriverActionException extends DriverException Chris@0: { Chris@0: /** Chris@0: * Initializes exception. Chris@0: * Chris@0: * @param string $template what is unsupported? Chris@0: * @param DriverInterface $driver driver instance Chris@0: * @param \Exception $previous previous exception Chris@0: */ Chris@0: public function __construct($template, DriverInterface $driver, \Exception $previous = null) Chris@0: { Chris@0: $message = sprintf($template, get_class($driver)); Chris@0: Chris@0: parent::__construct($message, 0, $previous); Chris@0: } Chris@0: }