| Fey documentation | Contained in the Fey distribution. |
Fey::Exceptions - Defines exceptions used in the core Fey classes
version 0.40
use Fey::Exceptions qw( param_error );
This module defines the exceptions which are used by the core Fey classes.
Loading this module defines the exception classes using
Exception::Class. This module also exports subroutines which can be
used as a shorthand to throw a specific type of exception.
This is the base class for other exception classes, and should not be used directly.
This exception indicates that the object is in a state that means it cannot execute a certain method.
This exception indicates that there was a problem with the parameters passed to a method.
This exception indicates that a virtual method was not overridden in the subclass on which it was called.
See Fey for details on how to report bugs.
Dave Rolsky <autarch@urth.org>
This software is Copyright (c) 2011 by Dave Rolsky.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
| Fey documentation | Contained in the Fey distribution. |
package Fey::Exceptions; BEGIN { $Fey::Exceptions::VERSION = '0.40'; } use strict; use warnings; my %E; BEGIN { %E = ( 'Fey::Exception' => { description => 'Generic exception within the Alzabo API. Should only be used as a base class.', }, 'Fey::Exception::ObjectState' => { description => 'You called a method on an object which its current state does not allow', isa => 'Fey::Exception', alias => 'object_state_error', }, 'Fey::Exception::Params' => { description => 'An exception generated when there is an error in the parameters passed in a method of function call', isa => 'Fey::Exception', alias => 'param_error', }, 'Fey::Exception::VirtualMethod' => { description => 'Indicates that the method called must be subclassed in the appropriate class', isa => 'Fey::Exception', alias => 'virtual_method', }, ); } use Exception::Class (%E); Fey::Exception->Trace(1); use base 'Exporter'; our @EXPORT_OK = map { $_->{alias} || () } values %E; 1; # ABSTRACT: Defines exceptions used in the core Fey classes
__END__