Data::Object::Role::Catchable
Data-Object Catchable Role
use Data::Object 'Class'; with Data::Object::Role::Catchable;
Data::Object::Role::Catchable is a role which provides functionality for catching thrown exceptions.
This package implements the following methods.
catch(Object $arg1, ClassName $arg2) : Int
Returns truthy if the objects passed are of the same kind.
my $catch = $self->catch($object, 'App::Exception');
To install Data::Object, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Data::Object
CPAN shell
perl -MCPAN -e shell install Data::Object
For more information on module installation, please visit the detailed CPAN module installation guide.