2017 © Pedro Peláez
 

library exception

b2r Exception Component

image

b2r/exception

b2r Exception Component

  • Thursday, March 9, 2017
  • by b2r
  • Repository
  • 1 Watchers
  • 0 Stars
  • 112 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

Common exceptions in my library, (*1)

Build Status, (*2)

  • All exception implements ExceptionInterface
  • All exception uses ExceptionTrait
  • CHANGELOG
  • Packagist

Exception classes

  • Exception
    • InvalidClassMemberException
    • InvalidMethodException
    • InvalidPropertyException
    • InvalidIndexException
    • InvalidKeyException
    • InvalidTypeException
    • InvalidParameterTypeException
    • IOException
    • FileNotFoundException
    • DirectoryNotFoundException
    • NameException
  • InvalidArgumentException
  • LogicException
  • RuntimeException
  • ValidationException

Utility/Helper classes

  • Utils: Utility functions
  • Finder: Lookup/resolve class name

InvalidTypeException sample

use b2r\Component\Exception\InvalidTypeException;

$e = new InvalidTypeException('$key', 'string|int', []); // Variable name, Valid type, Invalid type value
echo $e->message; #=>"$key must be of the type `string|int`, but `array` given"

Finder sample

Finder lookup/resolve class name easily., (*3)

use b2r\Component\Exception\Finder as E;

$e = E::Type(); #=>'b2r\Component\Exception\InvalidTypeException'
throw new $e('name', 'string|int', null);

The Versions

09/03 2017

dev-master

9999999-dev https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception

09/03 2017

v0.3.0

0.3.0.0 https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception

07/03 2017

v0.2.1

0.2.1.0 https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception

07/03 2017

v0.2.0

0.2.0.0 https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception

01/02 2017

v0.1.3

0.1.3.0 https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception

01/02 2017

0.1.0

0.1.0.0 https://github.com/b2r/php-exception

b2r Exception Component

  Sources   Download

MIT

The Requires

  • php >=7.0

 

by Avatar b2r

exception