4 * This file is part of the Behat Testwork.
5 * (c) Konstantin Kudryashov <ever.zet@gmail.com>
7 * For the full copyright and license information, please view the LICENSE
8 * file that was distributed with this source code.
11 namespace Behat\Testwork\ServiceContainer\Exception;
16 * Extension exception.
18 * @author Konstantin Kudryashov <ever.zet@gmail.com>
20 class ExtensionException extends RuntimeException implements ServiceContainerException
25 private $extensionName;
28 * Initializes exception.
30 * @param string $message
31 * @param string $extensionName
33 public function __construct($message, $extensionName)
35 $this->extensionName = $extensionName;
37 parent::__construct($message);
41 * Returns name of the extension that caused exception.
45 public function getExtensionName()
47 return $this->extensionName;