Yaf_Loader::getNamespacePath

Retieve path of a registered namespace

説明

public string Yaf_Loader::getNamespacePath(string $namespaces)

retrieve path of a registered namespace

パラメータ

namespace

a string of namespace.

戻り値

string path, if the namespace is not registered, then null default library will be returned

例1 Yaf_Loader::registerNamespaceexample

<?php
$loader = Yaf_Loader::getInstance("/var/application/lib");
$loader->registerNamespace("\Vendor\PHP", "/var/lib/php");

$loader->getNamespacePath("\Vendor\PHP"); // '/var/lib/php'
$loader->getNamespacePath("\Vendor\JSP"); // '/var/application/lib'

?>