Menu

## TwigSceneRenderer
in package

TwigSceneRenderer.php : 24

### Table of Contents

$game : Game
$templateValues : array<string|int, mixed>
$twig : Environment
__construct() : mixed
getSecurityPolicy() : SecurityPolicy
  Returns the current security policy.
render() : string
  Renders a given string in the context if a given viewpoint.

### Properties

#### $game

TwigSceneRenderer.php : 30
`private Game $game`

#### $templateValues

TwigSceneRenderer.php : 27
`private array<string|int, mixed> $templateValues`

#### $twig

TwigSceneRenderer.php : 26
`private Environment $twig`

### Methods

#### __construct()

TwigSceneRenderer.php : 29
`public __construct(Game $game) : mixed`

##### Parameters

$game : Game

##### Return values

mixed —

#### getSecurityPolicy()

TwigSceneRenderer.php : 117

Returns the current security policy.

`public getSecurityPolicy() : SecurityPolicy`

This method provides a hook.

##### Return values

SecurityPolicy —

#### render()

TwigSceneRenderer.php : 66

Renders a given string in the context if a given viewpoint.

`public render(string $string, Viewpoint $viewpoint[, bool $ignoreErrors = false ][, array<string|int, mixed> $templateValues = [] ]) : string`

##### Parameters

$string : string
$viewpoint : Viewpoint
$ignoreErrors : bool = false

  If set to true, errors are ignored and the unparsed string will be returned instead.

$templateValues : array<string|int, mixed> = []

##### Tags

throws
  InsecureTwigTemplateError
throws
  CharacterNotFoundException
throws
  LoaderError
throws
  SyntaxError

##### Return values

string —

## Search results