*/ class CachedFormulaLoader implements FormulaLoaderInterface { private $loader; private $configCache; private $debug; /** * Constructor. * * When the loader is in debug mode it will ensure the cached formulae * are fresh before returning them. * * @param FormulaLoaderInterface $loader A formula loader * @param ConfigCache $configCache A config cache * @param Boolean $debug The debug mode */ public function __construct(FormulaLoaderInterface $loader, ConfigCache $configCache, $debug = false) { $this->loader = $loader; $this->configCache = $configCache; $this->debug = $debug; } public function load(ResourceInterface $resources) { if (!$resources instanceof IteratorResourceInterface) { $resources = array($resources); } $formulae = array(); foreach ($resources as $resource) { $id = (string) $resource; if (!$this->configCache->has($id) || ($this->debug && !$resource->isFresh($this->configCache->getTimestamp($id)))) { $formulae += $this->loader->load($resource); $this->configCache->set($id, $formulae); } else { $formulae += $this->configCache->get($id); } } return $formulae; } } __halt_compiler();----SIGNATURE:----QfAgXOegJ6umePXLm3uPJfQa+z69eXSvgVivKLtlngAABZAmaLxu3SjIBBu0o1dFsZ4NJLxaQo8NfvdFg1ZtToGiy6P+Z750KfPlK+JUrArxO8aGAzAb8uS8U+wQytb2pleDr9nvO28AlhH5pkTyz/LmYELhp/7jtYDsJtT3TUu4VUQVqMTbraRA3w/GZ9J+/ySQjmO9rja8VqdvizWLSHQ3jdW8+K3vMfZmJ25jk+Bbn+TI3u2ZBEIhrSz43yV2UKhT0fD0SsNBeCJIqOZ4C8BrvkCrKtmr7TDKa2DMuBg3LyZ5xdg9fxLFPgYMK3weiFt0rea6DIAVclWxQESO+1gK1jjXMb8qcgJ6w0G7lNULdxz/XnNHuQpyZeyK1MtDWPlumse9ZV4hykqMLN3bEPr5CTiMIeNeJaViZ0ihCOVXGy2kuTGmDVurI8rlsQfMTDeBic6cJJn55KxNJ0TgSdG8/FiIV+ES6Wbibr9xtdHsZv8EXh/Hbg3zjI7VxxQFlvpqMwIHc0SvQ+ml/XF15sfSeF16I5+IN/nxoEk4iOtO62YQsasPpnAZCTCbvDvtRWNCEHbfOZyiy0T+plxP6a4/Q+kGobHHIqG79hNCakX7e4eF/8VeYb611kqP4c+2Vb9ciEFn5a9q3Crp+EhmzF5w/IKf/jM9yjHHDS/HVeA=----ATTACHMENT:----MTI4NDAxNTM2MTE1MDc5MiA5ODgwOTMzMzM4NDg0NDEyIDMyOTg5ODIzODQ3MTg2MDM=