Свойство | Type | Description | |
---|---|---|---|
_config | IReactSiteConfiguration | ||
_disposed | bool | ||
_engines | IJsEngine>.ConcurrentDictionary | ||
_factory | Func |
||
_fileSystem | IFileSystem | ||
_jsEngineSwitcher | |||
_pool | IJsPool | ||
_scriptLoadException |
Méthode | Description | |
---|---|---|
Dispose ( ) : void |
Clean up all engines
|
|
DisposeEngineForCurrentThread ( ) : void |
Disposes the JavaScript engine for the current thread.
|
|
EnsureValidState ( ) : void |
Ensures that this object has not been disposed, and that no error was thrown while loading the scripts.
|
|
GetEngine ( ) : IJsEngine |
Gets a JavaScript engine from the pool.
|
|
GetEngineForCurrentThread ( ) : IJsEngine |
Gets the JavaScript engine for the current thread. It is recommended to use GetEngine instead, which will pool/reuse engines.
|
|
JavaScriptEngineFactory ( |
Initializes a new instance of the JavaScriptEngineFactory class.
|
|
ReturnEngineToPool ( IJsEngine engine ) : void |
Returns an engine to the pool so it can be reused
|
Méthode | Description | |
---|---|---|
CreatePool ( ) : IJsPool |
Creates a new JavaScript engine pool.
|
|
InitialiseEngine ( IJsEngine engine ) : void |
Loads standard React and Babel scripts into the engine.
|
Méthode | Description | |
---|---|---|
EngineIsUsable ( IJsEngine engine, bool allowMsie ) : bool |
Performs a sanity check to ensure the specified engine type is usable.
|
|
EnsureJsEnginesRegistered ( |
Ensures that some engines have been registered with JavaScriptEngineSwitcher. IF not, registers some default engines.
|
|
EnsureReactLoaded ( IJsEngine engine ) : void |
Ensures that React has been correctly loaded into the specified engine.
|
|
GetFactory ( |
Gets a factory for the most appropriate JavaScript engine for the current environment. The first functioning JavaScript engine with the lowest priority will be used.
|
|
LoadUserScripts ( IJsEngine engine ) : void |
Loads any user-provided scripts. Only scripts that don't need JSX transformation can run immediately here. JSX files are loaded in ReactEnvironment.
|
public DisposeEngineForCurrentThread ( ) : void | ||
Résultat | void |
public GetEngineForCurrentThread ( ) : IJsEngine | ||
Résultat | IJsEngine |
protected InitialiseEngine ( IJsEngine engine ) : void | ||
engine | IJsEngine | |
Résultat | void |
public JavaScriptEngineFactory ( |
||
jsEngineSwitcher | ||
config | IReactSiteConfiguration | |
fileSystem | IFileSystem | |
Résultat | System |
public ReturnEngineToPool ( IJsEngine engine ) : void | ||
engine | IJsEngine | Engine to return |
Résultat | void |
protected IReactSiteConfiguration _config | ||
Résultat | IReactSiteConfiguration |
protected ConcurrentDictionary |
||
Résultat | IJsEngine>.ConcurrentDictionary |
protected JsEngineSwitcher,JavaScriptEngineSwitcher.Core _jsEngineSwitcher | ||
Résultat |