API Documentation

Controller/Plugin/ErrorHandler.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Controller
subpackage
Plugins
Classes
Zend_Controller_Plugin_ErrorHandler

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Controller_Plugin_ErrorHandler

Extends from
Zend_Controller_Plugin_Abstract
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Controller
subpackage
Plugins
uses
Zend_Controller_Plugin_Abstract
version
$Id: ErrorHandler.php 20246 2010-01-12 21:36:08Z dasprid $
Constants
EXCEPTION_NO_CONTROLLER
EXCEPTION_NO_ACTION
EXCEPTION_NO_ROUTE
EXCEPTION_OTHER
Properties
$_errorModule
$_errorController
$_errorAction
$_isInsideErrorHandlerLoop
$_exceptionCountAtFirstEncounter
Methods
__construct
setErrorHandler
setErrorHandlerModule
getErrorHandlerModule
setErrorHandlerController
getErrorHandlerController
setErrorHandlerAction
getErrorHandlerAction
routeShutdown
postDispatch
_handleError

Description

Handle exceptions that bubble up based on missing controllers, actions, or application errors, and forward to an error handler.

Constants

EXCEPTION_NO_CONTROLLER

 EXCEPTION_NO_CONTROLLER = 'EXCEPTION_NO_CONTROLLER'

Const - No controller exception; controller does not exist

Details

value
EXCEPTION_NO_CONTROLLER

EXCEPTION_NO_ACTION

 EXCEPTION_NO_ACTION = 'EXCEPTION_NO_ACTION'

Const - No action exception; controller exists, but action does not

Details

value
EXCEPTION_NO_ACTION

EXCEPTION_NO_ROUTE

 EXCEPTION_NO_ROUTE = 'EXCEPTION_NO_ROUTE'

Const - No route exception; no routing was possible

Details

value
EXCEPTION_NO_ROUTE

EXCEPTION_OTHER

 EXCEPTION_OTHER = 'EXCEPTION_OTHER'

Const - Other Exception; exceptions thrown by application controllers

Details

value
EXCEPTION_OTHER

Properties

$_errorAction

string $_errorAction = 'error'

Action to use for errors; defaults to 'error'

Details

$_errorAction
string
visibility
protected
default
error
final
false
static
false

$_errorController

string $_errorController = 'error'

Controller to use for errors; defaults to 'error'

Details

$_errorController
string
visibility
protected
default
error
final
false
static
false

$_errorModule

string $_errorModule = ''

Module to use for errors; defaults to default module in dispatcher

Details

$_errorModule
string
visibility
protected
default
final
false
static
false

$_exceptionCountAtFirstEncounter

int $_exceptionCountAtFirstEncounter = '0'

Exception count logged at first invocation of plugin

Details

$_exceptionCountAtFirstEncounter
int
visibility
protected
default
0
final
false
static
false

$_isInsideErrorHandlerLoop

bool $_isInsideErrorHandlerLoop = 'false'

Flag; are we already inside the error handler loop?

Details

$_isInsideErrorHandlerLoop
bool
visibility
protected
default
false
final
false
static
false

Methods

__construct

__construct( Array $options = array ) : void

Constructor

Options may include: - module - controller - action

Arguments
$options
Array
Details
visibility
public
final
false
static
false

_handleError

_handleError( Zend_Controller_Request_Abstract $request ) : void

Handle errors and exceptions

If the 'noErrorHandler' front controller flag has been set, returns early.

Arguments
$request
Zend_Controller_Request_Abstract
Details
visibility
protected
final
false
static
false

getErrorHandlerAction

getErrorHandlerAction( ) : string

Retrieve the current error handler action

Output
string
Details
visibility
public
final
false
static
false

getErrorHandlerController

getErrorHandlerController( ) : string

Retrieve the current error handler controller

Output
string
Details
visibility
public
final
false
static
false

getErrorHandlerModule

getErrorHandlerModule( ) : string

Retrieve the current error handler module

Output
string
Details
visibility
public
final
false
static
false

postDispatch

postDispatch( Zend_Controller_Request_Abstract $request ) :

Post dispatch hook -- check for exceptions and dispatch error handler if necessary

Arguments
$request
Zend_Controller_Request_Abstract
Details
visibility
public
final
false
static
false

routeShutdown

routeShutdown( Zend_Controller_Request_Abstract $request ) :

Route shutdown hook -- Ccheck for router exceptions

Arguments
$request
Zend_Controller_Request_Abstract
Details
visibility
public
final
false
static
false

setErrorHandler

setErrorHandler( array $options = array ) : Zend_Controller_Plugin_ErrorHandler

setErrorHandler() - setup the error handling options

Arguments
$options
array
Details
visibility
public
final
false
static
false

setErrorHandlerAction

setErrorHandlerAction( string $action ) : Zend_Controller_Plugin_ErrorHandler

Set the action name for the error handler

Arguments
$action
string
Details
visibility
public
final
false
static
false

setErrorHandlerController

setErrorHandlerController( string $controller ) : Zend_Controller_Plugin_ErrorHandler

Set the controller name for the error handler

Arguments
$controller
string
Details
visibility
public
final
false
static
false

setErrorHandlerModule

setErrorHandlerModule( string $module ) : Zend_Controller_Plugin_ErrorHandler

Set the module name for the error handler

Arguments
$module
string
Details
visibility
public
final
false
static
false
Documentation was generated by DocBlox.