Further modules included.
[yaffs-website] / web / modules / contrib / libraries / src / ExternalLibrary / PhpFile / PhpRequireLoader.php
1 <?php
2
3 namespace Drupal\libraries\ExternalLibrary\PhpFile;
4
5 /**
6  * Provides a PHP file loader using PHP's require_once.
7  *
8  * @todo Provide a separate PhpIncludeOnceLoader.
9  */
10 class PhpRequireLoader implements PhpFileLoaderInterface {
11
12   /**
13    * {@inheritdoc}
14    */
15   public function load($file) {
16     // @todo Because libraries cannot be loaded twice it should be possible to
17     //   use 'require' instead of 'require_once'.
18     /** @noinspection PhpIncludeInspection */
19     require_once $file;
20   }
21
22 }