[ Index ]
 

Code source de PHP PEAR 1.4.5

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/PEAR/ -> Autoloader.php (sommaire)

Class auto-loader PHP versions 4

Author: Stig Bakken <ssb@php.net>
Copyright: 1997-2006 The PHP Group
License: http://www.php.net/license/3_0.txt PHP License 3.0
Version: CVS: $Id: Autoloader.php,v 1.13 2006/01/06 04:47:36 cellog Exp $
Poids: 223 lignes (7 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 1 fichier
 PEAR.php

Définit 1 class

PEAR_Autoloader:: (5 méthodes):
  addAutoload()
  removeAutoload()
  addAggregateObject()
  removeAggregateObject()
  __call()


Classe: PEAR_Autoloader  - X-Ref

This class is for objects where you want to separate the code for
some methods into separate classes.  This is useful if you have a
class with not-frequently-used methods that contain lots of code
that you would like to avoid always parsing.

The PEAR_Autoloader class provides autoloading and aggregation.
The autoloading lets you set up in which classes the separated
methods are found.  Aggregation is the technique used to import new
methods, an instance of each class providing separated methods is
stored and called every time the aggregated method is called.

addAutoload($method, $classname = null)   X-Ref
Add one or more autoload entries.

param: string $method     which method to autoload
param: string $classname  (optional) which class to find the method in.
return: void

removeAutoload($method)   X-Ref
Remove an autoload entry.

param: string $method  which method to remove the autoload entry for
return: bool TRUE if an entry was removed, FALSE if not

addAggregateObject($classname)   X-Ref
Add an aggregate object to this object.  If the specified class
is not defined, loading it will be attempted following PEAR's
file naming scheme.  All the methods in the class will be
aggregated, except private ones (name starting with an
underscore) and constructors.

param: string $classname  what class to instantiate for the object.
return: void

removeAggregateObject($classname)   X-Ref
Remove an aggregate object.

param: string $classname  the class of the object to remove
return: bool  TRUE if an object was removed, FALSE if not

__call($method, $args, &$retval)   X-Ref
Overloaded object call handler, called each time an
undefined/aggregated method is invoked.  This method repeats
the call in the right aggregate object and passes on the return
value.

param: string $method  which method that was called
param: string $args    An array of the parameters passed in the
return: mixed  The return value from the aggregated method, or a PEAR



Généré le : Sun Feb 25 14:08:00 2007 par Balluche grâce à PHPXref 0.7