Описание
$object_name
= "PHP"
[, array $variables
= array()
[, array $extensions
= array()
[, bool $report_uncaught_exceptions
= TRUE
]]]] )Constructs a new V8Js object.
Список параметров
-
object_name
-
The name of the object passed to Javascript.
-
variables
-
Map of PHP variables that will be available in Javascript. Must be an associative array in format array("name-for-js" => "name-of-php-variable"). Defaults to empty array.
-
extensions
-
List of extensions registered using V8Js::registerExtension() which should be available in the Javascript context of the created V8Js object.
Замечание:
Extensions registered to be enabled automatically do not need to be listed in this array. Also if an extension has dependencies, those dependencies can be omitted as well. Defaults to empty array.
-
report_uncaught_exceptions
-
Controls whether uncaught Javascript exceptions are reported immediately or not. Defaults to
TRUE
. If set toFALSE
the uncaught exception can be accessed using V8Js::getPendingException().
Возвращаемые значения
Returns a new V8Js context object.
- PHP Руководство
- Функции по категориям
- Индекс функций
- Справочник функций
- Другие базовые расширения
- V8 Javascript Engine Integration
- Функция V8Js::__construct() - Construct a new V8Js object
- Функция V8Js::executeString() - Execute a string as Javascript code
- Функция V8Js::getExtensions() - Return an array of registered extensions
- Функция V8Js::getPendingException() - Return pending uncaught Javascript exception
- Функция V8Js::registerExtension() - Register Javascript extensions for V8Js
Коментарии
404 Not Found