Skip to content
Travis edited this page Mar 13, 2014 · 6 revisions

Box\Autoloader

Autoloader - The Frood autoloader.

.. Raped.

  • Class name: Autoloader
  • Namespace: Box

Properties

$_classPath

private string $_classPath
  • Visibility: private

Methods

\Box\Autoloader::__construct()

mixed Box\Autoloader::\Box\Autoloader::__construct()()

Construct a new Box autoloader.

It will automatically register itself.

  • Visibility: public

\Box\Autoloader::autoload()

mixed Box\Autoloader::\Box\Autoloader::autoload()(string $name)

Attempts to load the given class.

  • Visibility: public

Arguments

  • $name string - <p>The name of the class to load.</p>

\Box\Autoloader::unregister()

mixed Box\Autoloader::\Box\Autoloader::unregister()()

Unregister the autoloader. Persist and clean memory cache.

  • Visibility: public

\Box\Autoloader::_register()

mixed Box\Autoloader::\Box\Autoloader::_register()()

Register the autoloader.

  • Visibility: private

\Box\Autoloader::_classNameToPath()

null|string Box\Autoloader::\Box\Autoloader::_classNameToPath()(string $name)

Convert a class name to a path to a file containing the class definition.

Used by the autoloader.

  • Visibility: private

Arguments

  • $name string - <p>The name of the class.</p>

\Box\Autoloader::_searchFiles()

null|string Box\Autoloader::\Box\Autoloader::_searchFiles()(string $classPath, string $regex)

Internally used method. Used by _classNameToPath.

  • Visibility: private

Arguments

  • $classPath string - <p>The directory to search in.</p>
  • $regex string - <p>The regular expression to match on the full path.</p>

\Box\Autoloader::_getFiles()

array Box\Autoloader::\Box\Autoloader::_getFiles()(string $classPath, array $files)

Internally used method. Used by addClassPath to cache all files in the newly added class path.

  • Visibility: private
  • This method is static.

Arguments

  • $classPath string - <p>The directory to search in.</p>
  • $files array

Clone this wiki locally