/**
* @return Enlight_Template_Manager
*/
public function factory( Enlight_Event_EventManager
$eventManager,
Enlight_Components_Snippet_Resource
$snippetResource,
EscaperInterface
$escaper,
array
$templateConfig,
array
$securityConfig,
array
$backendOptions ) { $template = Enlight_Class::
Instance(Enlight_Template_Manager::
class,
[null,
$backendOptions]);
\
assert($template instanceof Enlight_Template_Manager
);
$template->
enableSecurity(new Security($template,
$securityConfig));
$template->
setOptions($templateConfig);
$template->
setEventManager($eventManager);
$template->
registerResource('snippet',
$snippetResource);
/* @phpstan-ignore-next-line is handled by magic method `\Smarty_Internal_TemplateBase::__call` and will set the property `\Smarty::$default_resource_type` */
$template->
setDefaultResourceType('snippet'
);