Beispiel #1
0
 /**
  * Adds a new $classname to $filename mapping to the map array.
  * The new map array is written to apc or file.
  *
  * @param string $class Classname is the lookup key for $filename.
  * @param string $file  Filename is the file to load.
  *
  * @return bool True if added to map.
  */
 public static function addMapping($class, $file)
 {
     self::$autoloaderMap = array_merge((array) self::$autoloaderMap, [$class => $file]);
     if (defined('APC') and APC === true) {
         return self::writeAutoloadingMapApc(self::$autoloaderMap);
     }
     return self::writeAutoloadingMapFile(self::$autoloaderMap);
 }