respect-validation/library/Exceptions/TypeException.php
paul karikari 5a326b6c97
Apply contribution guidelines to "Type" rule
Also add integration test for Type rule.

Signed-off-by: Paul Karikari <paulkarikari1@gmail.com>
Co-Authored-By: Henrique Moody <henriquemoody@gmail.com>
2018-06-15 22:12:17 +02:00

36 lines
822 B
PHP

<?php
/*
* This file is part of Respect/Validation.
*
* (c) Alexandre Gomes Gaigalas <alexandre@gaigalas.net>
*
* For the full copyright and license information, please view the "LICENSE.md"
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace Respect\Validation\Exceptions;
/**
* Exceptions thrown by Type rule.
*
* @author Henrique Moody <henriquemoody@gmail.com>
* @author Paul Karikari <paulkarikari1@gmail.com>
*/
final class TypeException extends ValidationException
{
/**
* {@inheritdoc}
*/
public static $defaultTemplates = [
self::MODE_DEFAULT => [
self::STANDARD => '{{name}} must be {{type}}',
],
self::MODE_NEGATIVE => [
self::STANDARD => '{{name}} must not be {{type}}',
],
];
}