Fixed bug #12508: Log usage of XLLfile to deprecation log (thanks to Steffen Gebert)
[Packages/TYPO3.CMS.git] / t3lib / error / interface.t3lib_error_errorhandlerinterface.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 2009 Ingo Renner <ingo@typo3.org>
6 * All rights reserved
7 *
8 * This script is part of the TYPO3 project. The TYPO3 project is
9 * free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * The GNU General Public License can be found at
15 * http://www.gnu.org/copyleft/gpl.html.
16 *
17 * This script is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
21 *
22 * This copyright notice MUST APPEAR in all copies of the script!
23 ***************************************************************/
24
25
26
27 /**
28 * Error handler interface for TYPO3
29 *
30 * This file is a backport from FLOW3
31 *
32 * @package TYPO3
33 * @subpackage t3lib_error
34 * @version $Id: ErrorHandlerInterface.php 3195 2009-09-17 11:27:14Z k-fish $
35 */
36 interface t3lib_error_ErrorHandlerInterface {
37
38 /**
39 * Registers this class as default error handler
40 *
41 * @param integer The integer representing the E_* error level which should be
42 * handled by the registered error handler.
43 * @return void
44 */
45 public function __construct($errorHandlerErrors);
46
47 /**
48 * Defines which error levels should result in an exception thrown.
49 *
50 * @param integer The integer representing the E_* error level to handle as exceptions
51 * @return void
52 */
53 public function setExceptionalErrors($exceptionalErrors);
54
55 /**
56 * Handles an error.
57 * If the error is registered as exceptionalError it will by converted into an exception, to be handled
58 * by the configured exceptionhandler. Additionall the error message is written to the configured logs.
59 * If TYPO3_MODE is 'BE' the error message is also added to the flashMessageQueue, in FE the error message
60 * is displayed in the admin panel (as TsLog message)
61 *
62 * @param integer The error level - one of the E_* constants
63 * @param string The error message
64 * @param string Name of the file the error occurred in
65 * @param integer Line number where the error occurred
66 * @return void
67 * @throws t3lib_error_Exception with the data passed to this method if the error is registered as exceptionalError
68 */
69 public function handleError($errorLevel, $errorMessage, $errorFile, $errorLine);
70 }
71
72 ?>