Exception - InvalidUrlException - an exception used while url is invalid

This commit is contained in:
Meritoo
2017-08-30 21:27:36 +02:00
parent b5e63ff619
commit aeea1df04b

View File

@@ -0,0 +1,23 @@
<?php
namespace Meritoo\Common\Exception\Regex;
/**
* An exception used while url is invalid
*
* @author Krzysztof Niziol <krzysztof.niziol@meritoo.pl>
* @copyright Meritoo.pl
*/
class InvalidUrlException extends \Exception
{
/**
* Class constructor
*
* @param string $url Invalid url
*/
public function __construct($url)
{
$message = sprintf('Url \'%s\' is invalid. Is there everything ok?', $url);
parent::__construct($message);
}
}