dosamigos\google\maps\Map::getClosureScopedVariablesScript PHP Метод

getClosureScopedVariablesScript() защищенный Метод

protected getClosureScopedVariablesScript ( ) : string
Результат string
    protected function getClosureScopedVariablesScript()
    {
        $js = [];
        foreach ($this->getClosureScopedVariables() as $name => $value) {
            if ($value !== null) {
                if (!$value instanceof JsExpression && strpos('{', $value) !== false) {
                    $value = is_string($value) ? "'{$value}'" : $value;
                }
                $value = " = {$value}";
            }
            $js[] = "var {$name}{$value};";
        }
        return implode("\n", $js);
    }