apidoc
[ class tree: apidoc ] [ index: apidoc ] [ all elements ]

Class: PEAR_Registry

Source Location: /PEAR-1.3.5/PEAR/Registry.php

Class Overview

PEAR
   |
   --PEAR_Registry

Administration class used to maintain the installed package database.


Author(s):

Variables

Methods


Inherited Variables

Inherited Methods

Class: PEAR

PEAR::PEAR()
Constructor. Registers this object in $_PEAR_destructor_object_list for destructor emulation if a destructor object exists.
PEAR::delExpect()
This method deletes all occurences of the specified element from the expected error codes stack.
PEAR::expectError()
This method is used to tell which errors you expect to get.
PEAR::getStaticProperty()
If you have a class that's mostly/entirely static, and you need static
PEAR::isError()
Tell whether a value is a PEAR error.
PEAR::loadExtension()
OS independant PHP extension load. Remember to take care on the correct extension name for case sensitive OSes.
PEAR::popErrorHandling()
Pop the last error handler used
PEAR::popExpect()
This method pops one element off the expected error codes stack.
PEAR::pushErrorHandling()
Push a new error handler on top of the error handler options stack. With this you can easily override the actual error handler for some code and restore it later with popErrorHandling.
PEAR::raiseError()
This method is a wrapper that returns an instance of the configured error class with this object's default error handling applied. If the $mode and $options parameters are not specified, the object's defaults are used.
PEAR::registerShutdownFunc()
Use this function to register a shutdown method for static classes.
PEAR::setErrorHandling()
Sets how errors generated by this object should be handled.
PEAR::staticPopErrorHandling()
PEAR::staticPushErrorHandling()
PEAR::throwError()
Simpler form of raiseError with fewer options. In most cases message, code and userinfo are enough.
PEAR::_PEAR()
Destructor (the emulated type of...). Does nothing right now, but is included for forward compatibility, so subclass destructors should always call it.

Class Details

[line 39]
Administration class used to maintain the installed package database.


[ Top ]


Class Variables

$filemap =  ''

[line 51]

File where the file map is stored

Type:   string


[ Top ]

$filemap_cache = array()

[line 80]

Cache of file map. Structure:

array( '/path/to/file' => 'package', ... )


Type:   array


[ Top ]

$lockfile =  ''

[line 56]

Name of file used for locking the registry

Type:   string


[ Top ]

$lock_fp =  null

[line 61]

File descriptor used during locking

Type:   resource


[ Top ]

$lock_mode =  0

[line 66]

Mode used during locking

Type:   int


[ Top ]

$pkginfo_cache = array()

[line 74]

Cache of package information. Structure:

array( 'package' => array('id' => ... ), ... )


Type:   array


[ Top ]

$statedir =  ''

[line 46]

Directory where registry files are stored.

Type:   string


[ Top ]



Method Detail

PEAR_Registry (Constructor)   [line 93]

PEAR_Registry PEAR_Registry( [string $pear_install_dir = PEAR_INSTALL_DIR])

PEAR_Registry constructor.
  • Access: public

Parameters:

string   $pear_install_dir   —  (optional) PEAR install directory (for .php files)

[ Top ]

addPackage   [line 422]

void addPackage( $package, $info)


Parameters:

   $package   — 
   $info   — 

[ Top ]

checkFileMap   [line 502]

string checkFileMap( string $path)

Test whether a file belongs to a package.
  • Return: which package the file belongs to, or an empty string if the file does not belong to an installed package
  • Access: public

Parameters:

string   $path   —  file path, absolute or relative to the pear install dir

[ Top ]

deletePackage   [line 445]

void deletePackage( $package)


Parameters:

   $package   — 

[ Top ]

listPackages   [line 409]

void listPackages( )


[ Top ]

packageExists   [line 383]

void packageExists( $package)


Parameters:

   $package   — 

[ Top ]

packageInfo   [line 396]

void packageInfo( [ $package = null], [ $key = null])


Parameters:

   $package   — 
   $key   — 

[ Top ]

readFileMap   [line 235]

void readFileMap( )


[ Top ]

rebuildFileMap   [line 198]

void rebuildFileMap( )


[ Top ]

updatePackage   [line 460]

void updatePackage( $package, $info, [ $merge = true])


Parameters:

   $package   — 
   $info   — 
   $merge   — 

[ Top ]

_packageFileName   [line 168]

string _packageFileName( string $package)

Get the name of the file where data for a given package is stored.
  • Return: registry file name
  • Access: public

Parameters:

string   $package   —  package name

[ Top ]


Documentation generated on Mon, 11 Mar 2019 14:24:00 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.