PHP 8.2.31
Preview: TemplateWrapper.php Size: 1.76 KB
/home/nshryvcy/himaltourism.com/wp-content/plugins/mailpoet/vendor-prefixed/twig/twig/src/TemplateWrapper.php

<?php
namespace MailPoetVendor\Twig;
if (!defined('ABSPATH')) exit;
final class TemplateWrapper
{
 private $env;
 private $template;
 public function __construct(Environment $env, Template $template)
 {
 $this->env = $env;
 $this->template = $template;
 }
 public function render(array $context = []) : string
 {
 // using func_get_args() allows to not expose the blocks argument
 // as it should only be used by internal code
 return $this->template->render($context, \func_get_args()[1] ?? []);
 }
 public function display(array $context = [])
 {
 // using func_get_args() allows to not expose the blocks argument
 // as it should only be used by internal code
 $this->template->display($context, \func_get_args()[1] ?? []);
 }
 public function hasBlock(string $name, array $context = []) : bool
 {
 return $this->template->hasBlock($name, $context);
 }
 public function getBlockNames(array $context = []) : array
 {
 return $this->template->getBlockNames($context);
 }
 public function renderBlock(string $name, array $context = []) : string
 {
 $context = $this->env->mergeGlobals($context);
 $level = \ob_get_level();
 if ($this->env->isDebug()) {
 \ob_start();
 } else {
 \ob_start(function () {
 return '';
 });
 }
 try {
 $this->template->displayBlock($name, $context);
 } catch (\Throwable $e) {
 while (\ob_get_level() > $level) {
 \ob_end_clean();
 }
 throw $e;
 }
 return \ob_get_clean();
 }
 public function displayBlock(string $name, array $context = [])
 {
 $this->template->displayBlock($name, $this->env->mergeGlobals($context));
 }
 public function getSourceContext() : Source
 {
 return $this->template->getSourceContext();
 }
 public function getTemplateName() : string
 {
 return $this->template->getTemplateName();
 }
 public function unwrap()
 {
 return $this->template;
 }
}

Directory Contents

Dirs: 11 × Files: 18

Name Size Perms Modified Actions
Cache DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Error DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Extension DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Loader DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Node DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Profiler DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Sandbox DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
Util DIR
- drwxr-xr-x 2023-04-04 05:35:39
Edit Download
3.09 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
12.59 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
23.03 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
9.59 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
522 B lrw-r--r-- 2023-04-04 05:35:39
Edit Download
0 B lrw-r--r-- 2023-04-04 05:35:39
Edit Download
14.03 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
542 B lrw-r--r-- 2023-04-04 05:35:39
Edit Download
1.10 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
8.64 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
476 B lrw-r--r-- 2023-04-04 05:35:39
Edit Download
6.88 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
1.76 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
3.34 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
2.18 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
2.07 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
1.86 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download
1.42 KB lrw-r--r-- 2023-04-04 05:35:39
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).