Eidolon::Core::Exceptions - Eidolon core exception list.


Eidolon documentation Contained in the Eidolon distribution.

Index


Code Index:

NAME

Top

Eidolon::Core::Exceptions - Eidolon core exception list.

SYNOPSIS

Top

In error handler of your application (lib/Example/Error.pm) you could write:

    if ($e eq "CoreError::AbstractMethod")
    {
        print "Abstract method called";
    }
    elsif ($e eq "CoreError::CGI::InvalidPOST")
    {
        print "Malformed POST request";
    }

DESCRIPTION

Top

The Eidolon::Core::Exceptions package creates core exceptions that are used by various core packages.

EXCEPTIONS

Top

_Error

Base Eidolon exception. All other exceptions subclass it.

CoreError

Base core exception. All other core exceptions subclass it.

CoreError::Compile

Compilation error. Thrown when driver or controller raised perl compile error during require or use.

CoreError::AbstractMethod

Abstract method error. Thrown when abstract method is called.

CoreError::NoRouter

No router defined. Raised when application has no router driver defined in the application configuration file.

CoreError::NoErrorHandler

No error handler defined. Raised when there is no error handler defined in the application configuration.

CoreError::Loader

Driver loader exceptions. All other driver loader exceptions subclass it.

CoreError::Loader::InvalidDriver

Thrown when driver being loaded isn't subclassed from Eidolon::Driver class.

CoreError::Loader::AlreadyLoaded

Thrown when driver of the given type is already loaded.

CoreError::CGI

CGI error. All other CGI errors subclass this exception.

CoreError::CGI::MaxPost

POST request size limit exceeded.

CoreError::CGI::InvalidPOST

Malformed POST request.

CoreError::CGI::FileSave

Error saving uploaded file (during multipart/form-data form submission).

SEE ALSO

Top

Eidolon

LICENSE

Top

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

AUTHOR

Top

Anton Belousov, <abel@cpan.org>

COPYRIGHT

Top


Eidolon documentation Contained in the Eidolon distribution.

package Eidolon::Core::Exceptions;
# ==============================================================================
#
#   Eidolon
#   Copyright (c) 2009, Atma 7
#   ---
#   Eidolon/Core/Exceptions.pm - core exception list
#
# ==============================================================================

use warnings;
use strict;

our $VERSION = "0.02"; # 2009-05-14 04:42:05

use Eidolon::Core::Exception::Builder
(
    "CoreError" => 
    {
        "title" => "Core error"
    },

    "CoreError::Compile" => 
    {
        "isa"   => "CoreError",
        "title" => "Compile error"
    },

    "CoreError::AbstractMethod" => 
    {
        "isa"   => "CoreError",
        "title" => "Abstract method called"
    },

    "CoreError::NoRouter" =>
    {
        "isa"   => "CoreError",
        "title" => "Router not found, cannot proceed the request"
    },

    "CoreError::NoErrorHandler" =>
    {
        "isa"   => "CoreError",
        "title" => "No error handler defined for the application"
    },

    "CoreError::Loader" => 
    {
        "isa"   => "CoreError",
        "title" => "Driver loader error"
    }, 

    "CoreError::Loader::InvalidDriver" => 
    {
        "isa"   => "CoreError::Loader",
        "title" => "Invalid driver type"
    },

    "CoreError::Loader::AlreadyLoaded" => 
    {
        "isa"   => "CoreError::Loader",
        "title" => "This type of driver is already loaded"
    },

    "CoreError::CGI" => 
    {
        "isa"   => "CoreError",
        "title" => "CGI error"
    },

    "CoreError::CGI::MaxPost" => 
    {
        "isa"   => "CoreError::CGI",
        "title" => "Too big POST request"
    },

    "CoreError::CGI::InvalidPOST" => 
    {
        "isa"   => "CoreError::CGI",
        "title" => "Invalid POST request"
    },

    "CoreError::CGI::FileSave" => 
    {
        "isa"   => "CoreError::CGI",
        "title" => "Error saving file"
    }
);

1;

__END__