Classloader PHPDoc

This commit is contained in:
Tim Nagel 2011-02-06 13:31:19 -08:00 committed by Fabien Potencier
parent 69672bad59
commit 108efc6ec9
3 changed files with 21 additions and 2 deletions

View File

@ -119,6 +119,10 @@ class ClassCollectionLoader
/**
* Adds brackets around each namespace if it's not already the case.
*
* @param string Namespace string
*
* @return string Namespaces with brackets
*/
static public function fixNamespaceDeclarations($source)
{
@ -162,6 +166,15 @@ class ClassCollectionLoader
return $output;
}
/**
* Writes a cache file
*
* @param string Filename
* @param string Temporary file content
*
* @throws \RuntimeException when a cache file cannot be written
*/
static protected function writeCacheFile($file, $content)
{
$tmpFile = tempnam(dirname($file), basename($file));

View File

@ -12,6 +12,7 @@
namespace Symfony\Component\ClassLoader;
/**
* A class loader that uses a mapping file to look up paths.
*
* @author Fabien Potencier <fabien.potencier@symfony-project.org>
*/
@ -19,6 +20,11 @@ class MapFileClassLoader
{
protected $map = array();
/**
* Constructor
*
* @param string Path to class mapping file
*/
public function __construct($file)
{
$this->map = require $file;

View File

@ -102,7 +102,7 @@ class UniversalClassLoader
/**
* Registers the directory to use as a fallback for namespaces.
*
* @return string|array $dirs A directory path or an array of directories
* @param string|array $dirs A directory path or an array of directories
*/
public function registerNamespaceFallback($dirs)
{
@ -112,7 +112,7 @@ class UniversalClassLoader
/**
* Registers the directory to use as a fallback for class prefixes.
*
* @return string|array $dirs A directory path or an array of directories
* @param string|array $dirs A directory path or an array of directories
*/
public function registerPrefixFallback($dirs)
{