previousPEAR::getStaticProperty() (Previous) (Next) PEAR::isError()next

View this page in Last updated: Sun, 18 Oct 2009
English | Brazilian Portuguese | Chinese | Dutch | French | German | Hungarian | Japanese | Polish | Russian | Spanish | Turkish

PEAR::registerShutdownFunc()

PEAR::registerShutdownFunc() – ustala funkcję zamykającą dla statycznych klas (package developer related)

Synopsis

require_once 'PEAR.php';

void PEAR::registerShutdownFunc ( array $func , array $var = array() )

Description

Wskazana funkcja jest wywołana zanim interpreter PHP zakończy działanie.

Parameter

  • array $func - nazwa klasy i funkcji.

  • array $var - możliwe wymagane parametry funkcji. Są one przekazywane do funkcji wg ich kolejności w tablicy.

Example

Użycie registerShutdownFunc()

<?php

require_once 'PEAR.php';

class 
myClass {

function 
myClass() 
{
 
PEAR::registerShutdownFunc(array('myClass''shutdown'), 
                            array(
'param1''param2'));
}

function 
shutdown$param1$param2)
{
 
// do something before we will die
}

}

?>
previousPEAR::getStaticProperty() (Previous) (Next) PEAR::isError()next

Download Documentation Last updated: Sun, 18 Oct 2009
Do you think that something on this page is wrong? Please file a bug report or add a note.
User Notes:
There are no user contributed notes for this page.