whitespace cleanup
[catagits/Catalyst-Runtime.git] / lib / Catalyst / Exception.pm
CommitLineData
a2f2cde9 1package Catalyst::Exception;
2
3cdcf968 3# XXX: See bottom of file for Exception implementation
a2f2cde9 4
a2f2cde9 5=head1 NAME
6
7Catalyst::Exception - Catalyst Exception Class
8
9=head1 SYNOPSIS
10
11 Catalyst::Exception->throw( qq/Fatal exception/ );
12
13See also L<Catalyst>.
14
15=head1 DESCRIPTION
16
17This is the Catalyst Exception class.
18
19=head1 METHODS
20
b5ecfcf0 21=head2 throw( $message )
a2f2cde9 22
b5ecfcf0 23=head2 throw( message => $message )
ebfde331 24
b5ecfcf0 25=head2 throw( error => $error )
a2f2cde9 26
27Throws a fatal exception.
28
3cdcf968 29=head2 meta
30
31Provided by Moose
32
2f381252 33=head1 AUTHORS
a2f2cde9 34
2f381252 35Catalyst Contributors, see Catalyst.pm
a2f2cde9 36
37=head1 COPYRIGHT
38
536bee89 39This library is free software. You can redistribute it and/or modify
a2f2cde9 40it under the same terms as Perl itself.
41
42=cut
43
ede5238f 44{
45 package Catalyst::Exception::Base;
3cdcf968 46
ede5238f 47 use Moose;
48 use namespace::clean -except => 'meta';
a80247cf 49
ede5238f 50 with 'Catalyst::Exception::Basic';
3cdcf968 51
ede5238f 52 __PACKAGE__->meta->make_immutable;
3cdcf968 53}
54
ede5238f 55{
56 package Catalyst::Exception;
57
58 use Moose;
59 use namespace::clean -except => 'meta';
60
61 use vars qw[$CATALYST_EXCEPTION_CLASS];
62
63 BEGIN {
64 extends($CATALYST_EXCEPTION_CLASS || 'Catalyst::Exception::Base');
65 }
66
67 __PACKAGE__->meta->make_immutable;
68}
e5ecd5bc 69
a2f2cde9 701;