Class Global
Represents a Global variable instance, importable/exportable across multiple modules.
Namespace: WasmerSharp
Assembly: WasmerSharp.dll
Syntax
public class Global : WasmerSharp.WasmerNativeHandle
Constructors
Global(WasmerValue, Boolean)
Creates a new global with the specified WasmerValue, or int, float, long and double which are implicitly convertible to it.
Declaration
public Global (WasmerSharp.WasmerValue val, bool mutable);
Parameters
Type | Name | Description |
---|---|---|
WasmerValue | val | The value to place on the global |
System.Boolean | mutable | Determines whether the global is mutable |
Properties
IsMutable
Determines whether this Global is mutable or not.
Declaration
public bool IsMutable { get; }
Property Value
Type | Description |
---|---|
System.Boolean | To be added. |
Value
Returns the value stored in this global
Declaration
public WasmerSharp.WasmerValue Value { get; }
Property Value
Type | Description |
---|---|
WasmerValue | To be added. |
ValueType
Returns the ValueType (type) of the global.
Declaration
public WasmerSharp.WasmerValueType ValueType { get; }
Property Value
Type | Description |
---|---|
WasmerValueType | To be added. |
Methods
Set(WasmerValue)
Sets the value of the global to the provided value, which can be a WasmerValue, or an int, long, float or double
Declaration
public void Set (WasmerSharp.WasmerValue value);
Parameters
Type | Name | Description |
---|---|---|
WasmerValue | value | The new value to set |