Exception-Base
view release on metacpan or search on metacpan
lib/Exception/Base.pm view on Meta::CPAN
968969970971972973974975976977978979980981982983984985986987
no
warnings
'uninitialized'
;
foreach
my
$key
(
keys
%args
) {
if
(
$attributes
->{
$key
}->{is} eq
'rw'
) {
$e
->{
$key
} =
$args
{
$key
};
};
};
# Defaults for this object
$e
->{defaults} = {
%$defaults
};
bless
$e
=>
$class
;
# Collect system data and eval error
$e
->_collect_system_data;
return
$e
;
};
=head1 METHODS
lib/Exception/Base.pm view on Meta::CPAN
106010611062106310641065106610671068106910701071107210731074107510761077107810791080
my
%args
=
@_
;
my
$attrs
=
$old_e
->ATTRS;
foreach
my
$key
(
keys
%args
) {
if
(
$attrs
->{
$key
}->{is} eq
'rw'
) {
$old_e
->{
$key
} =
$args
{
$key
};
};
};
$old_e
->PROPAGATE;
if
(
ref
$old_e
ne
$class
) {
# Rebless old object for new class
bless
$old_e
=>
$class
;
};
die
$old_e
;
};
=item I<CLASS>-E<gt>catch([$I<variable>])
The exception is recovered from I<variable> argument or C<$@> variable if
I<variable> argument was empty. Then also C<$@> is replaced with empty string
( run in 1.113 second using v1.01-cache-2.11-cpan-49f99fa48dc )