Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Differences Between: [Versions 310 and 400]

   1  <?php
   2  
   3  /*
   4   * This file is part of Mustache.php.
   5   *
   6   * (c) 2010-2017 Justin Hileman
   7   *
   8   * For the full copyright and license information, please view the LICENSE
   9   * file that was distributed with this source code.
  10   */
  11  
  12  /**
  13   * Mustache Cache interface.
  14   *
  15   * Interface for caching and loading Mustache_Template classes
  16   * generated by the Mustache_Compiler.
  17   */
  18  interface Mustache_Cache
  19  {
  20      /**
  21       * Load a compiled Mustache_Template class from cache.
  22       *
  23       * @param string $key
  24       *
  25       * @return bool indicates successfully class load
  26       */
  27      public function load($key);
  28  
  29      /**
  30       * Cache and load a compiled Mustache_Template class.
  31       *
  32       * @param string $key
  33       * @param string $value
  34       */
  35      public function cache($key, $value);
  36  
  37      /**
  38       * Set a logger instance.
  39       *
  40       * @param Mustache_Logger|Psr\Log\LoggerInterface $logger
  41       */
  42      public function setLogger($logger = null);
  43  }