responsecache example



    /** * How long to cache the current page for. * * @params int $time time to live in seconds. * * @return void */
    protected function cachePage(int $time)
    {
        Services::responsecache()->setTtl($time);
    }

    /** * Handles "auto-loading" helper files. * * @deprecated Use `helper` function instead of using this method. * * @codeCoverageIgnore * * @return void */
    

    protected ResponseCache $pageCache;

    /** * Constructor. */
    public function __construct(App $config)
    {
        $this->startTime = microtime(true);
        $this->config    = $config;

        $this->pageCache = Services::responsecache();
    }

    /** * Handles some basic app and environment setup. */
    public function initialize()
    {
        // Define environment variables         $this->bootstrapEnvironment();

        // Setup Exception Handling
Home | Imprint | This part of the site doesn't use cookies.