mirror of
https://github.com/Respect/Validation.git
synced 2024-06-04 14:52:17 +02:00
Remove prefix "Abstract" of non-abstract classes
This commit is contained in:
parent
70997912eb
commit
04db93bdad
|
@ -53,6 +53,8 @@ All notable changes of the Respect\Validation releases are documented in this fi
|
|||
- On exceptions, improve `Object` conversion to string (#399)
|
||||
- On exceptions, improve conversion of all values by using JSON (#399)
|
||||
- On exceptions, nested messages are displayed in a Markdown list (#588)
|
||||
- Rename exception class "AbstractGroupedException" to "GroupedValidationException" (#591)
|
||||
- Rename exception class "AbstractNestedException" to "NestedValidationException" (#591)
|
||||
- Rename rule "Arr" to "ArrayVal"
|
||||
- Rename rule "Bool" to "BoolType" (#426)
|
||||
- Rename rule "False" to "FalseVal" (#426)
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class AgeException extends AbstractNestedException
|
||||
class AgeException extends NestedValidationException
|
||||
{
|
||||
const BOTH = 0;
|
||||
const LOWER = 1;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class AllOfException extends AbstractGroupedException
|
||||
class AllOfException extends GroupedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class AtLeastException extends AbstractGroupedException
|
||||
class AtLeastException extends GroupedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class AttributeException extends AbstractNestedException
|
||||
class AttributeException extends NestedValidationException
|
||||
{
|
||||
const NOT_PRESENT = 0;
|
||||
const INVALID = 1;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class BetweenException extends AbstractNestedException
|
||||
class BetweenException extends NestedValidationException
|
||||
{
|
||||
const BOTH = 0;
|
||||
const LOWER = 1;
|
||||
|
|
|
@ -11,6 +11,6 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class CallException extends AbstractGroupedException
|
||||
class CallException extends GroupedValidationException
|
||||
{
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class CallbackException extends AbstractNestedException
|
||||
class CallbackException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class DomainException extends AbstractNestedException
|
||||
class DomainException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class EachException extends AbstractNestedException
|
||||
class EachException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class AbstractGroupedException extends AbstractNestedException
|
||||
class GroupedValidationException extends NestedValidationException
|
||||
{
|
||||
const NONE = 0;
|
||||
const SOME = 1;
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class KeySetException extends AbstractGroupedException
|
||||
class KeySetException extends GroupedValidationException
|
||||
{
|
||||
const STRUCTURE = 2;
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ namespace Respect\Validation\Exceptions;
|
|||
use RecursiveIteratorIterator;
|
||||
use SplObjectStorage;
|
||||
|
||||
class AbstractNestedException extends ValidationException implements NestedValidationExceptionInterface
|
||||
class NestedValidationException extends ValidationException implements NestedValidationExceptionInterface
|
||||
{
|
||||
/**
|
||||
* @var SplObjectStorage
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class NoneOfException extends AbstractNestedException
|
||||
class NoneOfException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -11,6 +11,6 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class NotException extends AbstractGroupedException
|
||||
class NotException extends GroupedValidationException
|
||||
{
|
||||
}
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class OneOfException extends AbstractNestedException
|
||||
class OneOfException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -18,7 +18,7 @@ class RecursiveExceptionIterator implements RecursiveIterator, Countable
|
|||
{
|
||||
private $exceptions;
|
||||
|
||||
public function __construct(AbstractNestedException $parent)
|
||||
public function __construct(NestedValidationException $parent)
|
||||
{
|
||||
$this->exceptions = $parent->getRelated();
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ class RecursiveExceptionIterator implements RecursiveIterator, Countable
|
|||
return false;
|
||||
}
|
||||
|
||||
return ($this->current() instanceof AbstractNestedException);
|
||||
return ($this->current() instanceof NestedValidationException);
|
||||
}
|
||||
|
||||
public function getChildren()
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
namespace Respect\Validation\Exceptions;
|
||||
|
||||
class ZendException extends AbstractNestedException
|
||||
class ZendException extends NestedValidationException
|
||||
{
|
||||
public static $defaultTemplates = [
|
||||
self::MODE_DEFAULT => [
|
||||
|
|
|
@ -15,15 +15,15 @@ namespace Respect\Validation\Exceptions;
|
|||
* phpunit has an issue with mocking exceptions when in HHVM:
|
||||
* https://github.com/sebastianbergmann/phpunit-mock-objects/issues/207
|
||||
*/
|
||||
class PrivateAbstractNestedException extends AbstractNestedException
|
||||
class PrivateNestedValidationException extends NestedValidationException
|
||||
{
|
||||
}
|
||||
|
||||
class AbstractNestedExceptionTest extends \PHPUnit_Framework_TestCase
|
||||
class NestedValidationExceptionTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
public function testItImplementsNestedValidationExceptionInterface()
|
||||
{
|
||||
$abstractNestedException = new PrivateAbstractNestedException();
|
||||
$abstractNestedException = new PrivateNestedValidationException();
|
||||
$this->assertInstanceOf('Respect\Validation\Exceptions\NestedValidationExceptionInterface',
|
||||
$abstractNestedException);
|
||||
}
|
Loading…
Reference in a new issue