2011-06-09 05:13:26 +02:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
* @package extension
|
|
|
|
* @copyright (c) 2011 phpBB Group
|
2011-12-31 13:32:52 +00:00
|
|
|
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
|
2011-06-09 05:13:26 +02:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @ignore
|
|
|
|
*/
|
|
|
|
if (!defined('IN_PHPBB'))
|
|
|
|
{
|
|
|
|
exit;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
2011-08-29 17:17:40 -04:00
|
|
|
* The interface extension meta classes have to implement to run custom code
|
|
|
|
* on enable/disable/purge.
|
2011-06-09 05:13:26 +02:00
|
|
|
*
|
|
|
|
* @package extension
|
|
|
|
*/
|
|
|
|
interface phpbb_extension_interface
|
|
|
|
{
|
2011-08-29 17:17:40 -04:00
|
|
|
/**
|
|
|
|
* enable_step is executed on enabling an extension until it returns false.
|
|
|
|
*
|
|
|
|
* Calls to this function can be made in subsequent requests, when the
|
|
|
|
* function is invoked through a webserver with a too low max_execution_time.
|
|
|
|
*
|
|
|
|
* @param mixed $old_state The return value of the previous call
|
|
|
|
* of this method, or false on the first call
|
|
|
|
* @return mixed Returns false after last step, otherwise
|
|
|
|
* temporary state which is passed as an
|
|
|
|
* argument to the next step
|
|
|
|
*/
|
|
|
|
public function enable_step($old_state);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Disables the extension.
|
|
|
|
*
|
2011-11-18 18:15:39 +01:00
|
|
|
* Calls to this function can be made in subsequent requests, when the
|
|
|
|
* function is invoked through a webserver with a too low max_execution_time.
|
2011-08-29 17:17:40 -04:00
|
|
|
*
|
2011-11-18 18:15:39 +01:00
|
|
|
* @param mixed $old_state The return value of the previous call
|
|
|
|
* of this method, or false on the first call
|
2011-08-29 17:17:40 -04:00
|
|
|
* @return null
|
|
|
|
*/
|
2011-11-18 18:15:39 +01:00
|
|
|
public function disable_step($old_state);
|
2011-08-29 17:17:40 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* purge_step is executed on purging an extension until it returns false.
|
|
|
|
*
|
|
|
|
* Calls to this function can be made in subsequent requests, when the
|
|
|
|
* function is invoked through a webserver with a too low max_execution_time.
|
|
|
|
*
|
|
|
|
* @param mixed $old_state The return value of the previous call
|
|
|
|
* of this method, or false on the first call
|
|
|
|
* @return mixed Returns false after last step, otherwise
|
|
|
|
* temporary state which is passed as an
|
|
|
|
* argument to the next step
|
|
|
|
*/
|
|
|
|
public function purge_step($old_state);
|
2011-06-09 05:13:26 +02:00
|
|
|
}
|