Struct DirectInvocationContext
What a host function called directly needs to access the guest. It is used by the generated bindings.
Assembly: WaaS.Core.dll
View Source
Declaration
public readonly struct DirectInvocationContext
Methods
LiftString(in StackValueItem, in StackValueItem)
View Source
Declaration
public string LiftString(in StackValueItem ptr, in StackValueItem length)
Returns
System.String
Parameters
| Type | Name |
|---|---|
| WaaS.Runtime.StackValueItem | ptr |
| WaaS.Runtime.StackValueItem | length |
LiftBorrowed<T>(in StackValueItem, IResourceType)
View Source
Declaration
public Borrowed<T> LiftBorrowed<T>(in StackValueItem index, IResourceType type) where T : IResourceImpl
Returns
WaaS.ComponentModel.Binding.Borrowed<T>
Parameters
| Type | Name |
|---|---|
| WaaS.Runtime.StackValueItem | index |
| WaaS.ComponentModel.Runtime.IResourceType | type |
Type Parameters
T
ReleaseBorrowed<T>(Borrowed<T>)
Ends a borrow lifted by WaaS.ComponentModel.Binding.DirectInvocationContext.LiftBorrowed%60%601(WaaS.Runtime.StackValueItem%40%2cWaaS.ComponentModel.Runtime.IResourceType) when the host function has returned.
View Source
Declaration
public void ReleaseBorrowed<T>(Borrowed<T> borrowed) where T : IResourceImpl
Parameters
| Type | Name |
|---|---|
| WaaS.ComponentModel.Binding.Borrowed<T> | borrowed |
Type Parameters
T
CheckResultPointer(uint, byte)
View Source
Declaration
public void CheckResultPointer(uint ptr, byte alignmentRank)
Parameters
| Type | Name |
|---|---|
System.UInt32 | ptr |
System.Byte | alignmentRank |
Store(uint, uint)
View Source
Declaration
public void Store(uint ptr, uint value)
Parameters
| Type | Name |
|---|---|
System.UInt32 | ptr |
System.UInt32 | value |
Store(uint, ulong)
View Source
Declaration
public void Store(uint ptr, ulong value)
Parameters
| Type | Name |
|---|---|
System.UInt32 | ptr |
System.UInt64 | value |
Store(uint, float)
View Source
Declaration
public void Store(uint ptr, float value)
Parameters
| Type | Name |
|---|---|
System.UInt32 | ptr |
System.Single | value |
Store(uint, double)
View Source
Declaration
public void Store(uint ptr, double value)
Parameters
| Type | Name |
|---|---|
System.UInt32 | ptr |
System.Double | value |
StoreString(uint, string)
Stores a string as a result. The pointer and the length are written at <code class="paramref">resultPointer</code>.
View Source
Declaration
public void StoreString(uint resultPointer, string value)
Parameters
| Type | Name |
|---|---|
System.UInt32 | resultPointer |
System.String | value |