[ Index ] |
|
Code source de PHP PEAR 1.4.5 |
[Code source] [Imprimer] [Statistiques]
PEAR_Registry PHP versions 4 and 5
Author: | Stig Bakken <ssb@php.net> |
Author: | Tomas V. V. Cox <cox@idecnet.com> |
Author: | Greg Beaver <cellog@php.net> |
Copyright: | 1997-2006 The PHP Group |
License: | http://www.php.net/license/3_0.txt PHP License 3.0 |
Version: | CVS: $Id: Registry.php,v 1.159 2006/12/20 19:34:03 cellog Exp $ |
Poids: | 2214 lignes (73 kb) |
Inclus ou requis: | 3 fois |
Référencé: | 0 fois |
Nécessite: | 7 fichiers PEAR/DependencyDB.php PEAR/Installer/Role.php PEAR.php System.php PEAR/ChannelFile.php PEAR/PackageFile/v1.php PEAR/PackageFile.php |
PEAR_Registry:: (69 méthodes):
PEAR_Registry()
hasWriteAccess()
setConfig()
_initializeChannelDirs()
_initializeDirs()
_initializeDepDB()
_PEAR_Registry()
_assertStateDir()
_assertChannelStateDir()
_assertChannelDir()
_packageFileName()
_channelFileName()
_getChannelAliasFileName()
_getChannelFromAlias()
_getAlias()
_channelDirectoryName()
_openPackageFile()
_closePackageFile()
_openChannelFile()
_closeChannelFile()
_rebuildFileMap()
_readFileMap()
_lock()
_unlock()
_packageExists()
_channelExists()
_addChannel()
_deleteChannel()
_isChannelAlias()
_packageInfo()
_channelInfo()
_listChannels()
_listPackages()
_listChannelPackages()
_listAllPackages()
_addPackage()
_addPackage2()
_updatePackage()
_updatePackage2()
_getPackage()
_getChannel()
packageExists()
channelExists()
isAlias()
packageInfo()
channelInfo()
channelName()
channelAlias()
listPackages()
listAllPackages()
listChannels()
addPackage()
addPackage2()
updateChannel()
deleteChannel()
addChannel()
deletePackage()
updatePackage()
updatePackage2()
getChannel()
getPackage()
getInstalledGroup()
getChannelValidator()
getChannels()
checkFileMap()
flushFileMap()
apiVersion()
parsePackageName()
parsedPackageNameToString()
Classe: PEAR_Registry - X-Ref
Administration class used to maintain the installed package database.PEAR_Registry($pear_install_dir = PEAR_INSTALL_DIR, $pear_channel = false,$pecl_channel = false) X-Ref |
PEAR_Registry constructor. param: string (optional) PEAR install directory (for .php files) param: PEAR_ChannelFile PEAR_ChannelFile object representing the PEAR channel, if param: PEAR_ChannelFile PEAR_ChannelFile object representing the PECL channel, if |
hasWriteAccess() X-Ref |
Pas de description |
setConfig(&$config) X-Ref |
Pas de description |
_initializeChannelDirs() X-Ref |
Pas de description |
_initializeDirs() X-Ref |
Pas de description |
_initializeDepDB() X-Ref |
Pas de description |
_PEAR_Registry() X-Ref |
PEAR_Registry destructor. Makes sure no locks are forgotten. |
_assertStateDir($channel = false) X-Ref |
Make sure the directory where we keep registry files exists. return: bool TRUE if directory exists, FALSE if it could not be |
_assertChannelStateDir($channel) X-Ref |
Make sure the directory where we keep registry files exists for a non-standard channel. param: string channel name return: bool TRUE if directory exists, FALSE if it could not be |
_assertChannelDir() X-Ref |
Make sure the directory where we keep registry files for channels exists return: bool TRUE if directory exists, FALSE if it could not be |
_packageFileName($package, $channel = false) X-Ref |
Get the name of the file where data for a given package is stored. param: string channel name, or false if this is a PEAR package param: string package name return: string registry file name |
_channelFileName($channel, $noaliases = false) X-Ref |
Get the name of the file where data for a given channel is stored. param: string channel name return: string registry file name |
_getChannelAliasFileName($alias) X-Ref |
param: string return: string |
_getChannelFromAlias($channel) X-Ref |
Get the name of a channel from its alias |
_getAlias($channel) X-Ref |
Get the alias of a channel from its alias or its name |
_channelDirectoryName($channel) X-Ref |
Get the name of the file where data for a given package is stored. param: string channel name, or false if this is a PEAR package param: string package name return: string registry file name |
_openPackageFile($package, $mode, $channel = false) X-Ref |
Pas de description |
_closePackageFile($fp) X-Ref |
Pas de description |
_openChannelFile($channel, $mode) X-Ref |
Pas de description |
_closeChannelFile($fp) X-Ref |
Pas de description |
_rebuildFileMap() X-Ref |
Pas de description |
_readFileMap() X-Ref |
Pas de description |
_lock($mode = LOCK_EX) X-Ref |
Lock the registry. param: integer lock mode, one of LOCK_EX, LOCK_SH or LOCK_UN. return: bool TRUE on success, FALSE if locking failed, or a |
_unlock() X-Ref |
Pas de description |
_packageExists($package, $channel = false) X-Ref |
Pas de description |
_channelExists($channel, $noaliases = false) X-Ref |
Determine whether a channel exists in the registry param: string Channel name param: bool if true, then aliases will be ignored return: boolean |
_addChannel($channel, $update = false, $lastmodified = false) X-Ref |
param: PEAR_ChannelFile Channel object param: donotuse param: string Last-Modified HTTP tag from remote request return: boolean|PEAR_Error True on creation, false if it already exists |
_deleteChannel($channel) X-Ref |
Deletion fails if there are any packages installed from the channel param: string|PEAR_ChannelFile channel name return: boolean|PEAR_Error True on deletion, false if it doesn't exist |
_isChannelAlias($alias) X-Ref |
Determine whether a channel exists in the registry param: string Channel Alias return: boolean |
_packageInfo($package = null, $key = null, $channel = 'pear.php.net') X-Ref |
param: string|null param: string|null param: string|null return: array|null |
_channelInfo($channel, $noaliases = false) X-Ref |
param: string Channel name param: bool whether to strictly retrieve info of channels, not just aliases return: array|null |
_listChannels() X-Ref |
Pas de description |
_listPackages($channel = false) X-Ref |
Pas de description |
_listChannelPackages($channel) X-Ref |
Pas de description |
_listAllPackages() X-Ref |
Pas de description |
_addPackage($package, $info) X-Ref |
Add an installed package to the registry param: string package name param: array package info (parsed by PEAR_Common::infoFrom*() methods) return: bool success of saving |
_addPackage2($info) X-Ref |
param: PEAR_PackageFile_v1|PEAR_PackageFile_v2 return: bool |
_updatePackage($package, $info, $merge = true) X-Ref |
param: string Package name param: array parsed package.xml 1.0 param: bool this parameter is only here for BC. Don't use it. |
_updatePackage2($info) X-Ref |
param: PEAR_PackageFile_v1|PEAR_PackageFile_v2 return: bool |
_getPackage($package, $channel = 'pear.php.net') X-Ref |
param: string Package name param: string Channel name return: PEAR_PackageFile_v1|PEAR_PackageFile_v2|null |
_getChannel($channel, $noaliases = false) X-Ref |
param: string channel name param: bool whether to strictly retrieve channel names return: PEAR_ChannelFile|PEAR_Error |
packageExists($package, $channel = 'pear.php.net') X-Ref |
param: string Package name param: string Channel name return: bool |
channelExists($channel, $noaliases = false) X-Ref |
param: string channel name param: bool if true, then aliases will be ignored return: bool |
isAlias($alias) X-Ref |
Determines whether the parameter is an alias of a channel param: string return: bool |
packageInfo($package = null, $key = null, $channel = 'pear.php.net') X-Ref |
param: string|null param: string|null param: string return: array|null |
channelInfo($channel = null, $noaliases = false) X-Ref |
Retrieve a raw array of channel data. Do not use this, instead use {@link getChannel()} for normal operations. Array structure is undefined in this method param: string channel name param: bool whether to strictly retrieve information only on non-aliases return: array|null|PEAR_Error |
channelName($channel) X-Ref |
param: string |
channelAlias($channel) X-Ref |
param: string |
listPackages($channel = false) X-Ref |
Pas de description |
listAllPackages() X-Ref |
Pas de description |
listChannels() X-Ref |
Pas de description |
addPackage($package, $info) X-Ref |
Add an installed package to the registry param: string|PEAR_PackageFile_v1|PEAR_PackageFile_v2 package name or object param: array package info (parsed by PEAR_Common::infoFrom*() methods) return: bool success of saving |
addPackage2($info) X-Ref |
Pas de description |
updateChannel($channel, $lastmodified = null) X-Ref |
For future expandibility purposes, separate this param: PEAR_ChannelFile |
deleteChannel($channel) X-Ref |
Deletion fails if there are any packages installed from the channel param: string|PEAR_ChannelFile channel name return: boolean|PEAR_Error True on deletion, false if it doesn't exist |
addChannel($channel, $lastmodified = false, $update = false) X-Ref |
param: PEAR_ChannelFile Channel object param: string Last-Modified header from HTTP for caching return: boolean|PEAR_Error True on creation, false if it already exists |
deletePackage($package, $channel = 'pear.php.net') X-Ref |
Pas de description |
updatePackage($package, $info, $merge = true) X-Ref |
Pas de description |
updatePackage2($info) X-Ref |
Pas de description |
getChannel($channel, $noaliases = false) X-Ref |
param: string channel name param: bool whether to strictly return raw channels (no aliases) return: PEAR_ChannelFile|PEAR_Error |
getPackage($package, $channel = 'pear.php.net') X-Ref |
param: string package name param: string channel name return: PEAR_PackageFile_v1|PEAR_PackageFile_v2|null |
getInstalledGroup($group) X-Ref |
Get PEAR_PackageFile_v[1/2] objects representing the contents of a dependency group that are installed. This is used at uninstall-time param: array return: array|false |
getChannelValidator($channel) X-Ref |
param: string channel name return: PEAR_Validate|false |
getChannels() X-Ref |
param: string channel name return: array an array of PEAR_ChannelFile objects representing every installed channel |
checkFileMap($path, $package = false, $api = '1.0', $attrs = false) X-Ref |
Test whether a file or set of files belongs to a package. If an array is passed in param: string|array file path, absolute or relative to the pear param: string|array name of PEAR package or array('package' => name, 'channel' => param: string API version - 1.1 will exclude any files belonging to a package param: array private recursion variable return: array|false which package and channel the file belongs to, or an empty |
flushFileMap() X-Ref |
Force a reload of the filemap |
apiVersion() X-Ref |
Get the expected API version. Channels API is version 1.1, as it is backwards compatible with 1.0 return: string |
parsePackageName($param, $defaultchannel = 'pear.php.net') X-Ref |
Parse a package name, or validate a parsed package name array param: string|array pass in an array of format return: array|PEAR_Error |
parsedPackageNameToString($parsed, $brief = false) X-Ref |
param: array return: string |
Généré le : Sun Feb 25 14:08:00 2007 | par Balluche grâce à PHPXref 0.7 |