Table of Contents

Class Context

Namespace
JavaScriptCore
Assembly
JavaScriptCore-6.0.dll
public sealed class Context : Object, IObject, INotifyPropertyChanged, IDisposable, IHandle, GTypeProvider
Inheritance
Context
Implements
Inherited Members

Constructors

Context(bool, params ConstructArgument[])

protected Context(bool owned, params ConstructArgument[] constructArguments)

Parameters

owned bool
constructArguments ConstructArgument[]

Context(IntPtr, bool)

protected Context(IntPtr ptr, bool ownedRef)

Parameters

ptr IntPtr
ownedRef bool

Fields

VirtualMachinePropertyDefinition

public static readonly Property<VirtualMachine?, Context> VirtualMachinePropertyDefinition

Field Value

Property<VirtualMachine, Context>

Properties

VirtualMachine

public VirtualMachine? VirtualMachine { get; }

Property Value

VirtualMachine

Methods

ClearException()

public void ClearException()

Evaluate(string, long)

public Value Evaluate(string code, long length)

Parameters

code string
length long

Returns

Value

EvaluateWithSourceUri(string, long, string, uint)

public Value EvaluateWithSourceUri(string code, long length, string uri, uint lineNumber)

Parameters

code string
length long
uri string
lineNumber uint

Returns

Value

GetCurrent()

public static Context? GetCurrent()

Returns

Context

GetException()

public Exception? GetException()

Returns

Exception

GetGType()

public static Type GetGType()

Returns

Type

GetGlobalObject()

public Value GetGlobalObject()

Returns

Value

GetValue(string)

public Value GetValue(string name)

Parameters

name string

Returns

Value

GetVirtualMachine()

public VirtualMachine GetVirtualMachine()

Returns

VirtualMachine

New()

public static Context New()

Returns

Context

NewWithVirtualMachine(VirtualMachine)

public static Context NewWithVirtualMachine(VirtualMachine vm)

Parameters

vm VirtualMachine

Returns

Context

PopExceptionHandler()

public void PopExceptionHandler()

PushExceptionHandler(ExceptionHandler)

public void PushExceptionHandler(ExceptionHandler handler)

Parameters

handler ExceptionHandler

SetValue(string, Value)

public void SetValue(string name, Value value)

Parameters

name string
value Value

Throw(string)

public void Throw(string errorMessage)

Parameters

errorMessage string

ThrowException(Exception)

public void ThrowException(Exception exception)

Parameters

exception Exception

ThrowWithName(string, string)

public void ThrowWithName(string errorName, string errorMessage)

Parameters

errorName string
errorMessage string