You are here

function xautoload_FinderPlugin_CheckIncludePath::findFile in X Autoload 7.3

Same name and namespace in other branches
  1. 7.5 legacy/lib/FinderPlugin/CheckIncludePath.php \xautoload_FinderPlugin_CheckIncludePath::findFile()
  2. 7.4 legacy/lib/FinderPlugin/CheckIncludePath.php \xautoload_FinderPlugin_CheckIncludePath::findFile()

Expect a class Aaa_Bbb_Ccc_Ddd to be in Aaa/Bbb/Ccc/Ddd.php, but consider the PHP include_path setting.

Parameters

xautoload_InjectedAPI_findFile $api: The InjectedAPI object.

string $path_fragment: First part of the path, for instance "Aaa/Bbb/".

string $path_suffix: Second part of the path, for instance "Ccc/Ddd.php".

Return value

bool|NULL TRUE, if the file was found. FALSE, otherwise.

Overrides xautoload_FinderPlugin_Interface::findFile

File

lib/FinderPlugin/CheckIncludePath.php, line 25

Class

xautoload_FinderPlugin_CheckIncludePath
This class is not used anywhere in xautoload, but could be used by other modules.

Code

function findFile($api, $path_fragment, $path_suffix) {
  $path = $path_fragment . $path_suffix;
  if ($api
    ->suggestFile_checkIncludePath($path)) {
    return TRUE;
  }
}