Class ServerExtensionProxy
Namespace: DotBoxD.Plugins.Runtime.Rpc
Assembly: DotBoxD.Plugins.dll
A runtime proxy that implements a server-extension interface by marshaling each call through an
installed batch kernel. Arguments are converted to sandbox values, the verified IR runs request/
response via DotBoxD.Plugins.Kernel.InstalledKernel.InvokeServerExtensionAsync(System.Collections.Generic.IReadOnlyList{DotBoxD.Kernels.Sandbox.SandboxValue},System.Threading.CancellationToken), and the result is marshaled
back to the method’s return type, so
server.ServerExtension<IMonsterKiller>().KillMonsters(ids) returns real C# objects.
The service is expected to declare a single batch method; synchronous, Task<T>, and
ValueTask<T> return shapes are supported.
public class ServerExtensionProxy : DispatchProxyInheritance
Section titled “Inheritance”object ← DispatchProxy ← ServerExtensionProxy
Inherited Members
Section titled “Inherited Members”DispatchProxy.Create(Type, Type), DispatchProxy.Create<T, TProxy>(), DispatchProxy.Invoke(MethodInfo?, object?[]?), object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Methods
Section titled “Methods”Create<TService>(InstalledKernel)
Section titled “ Create<TService>(InstalledKernel)”public static TService Create<TService>(InstalledKernel kernel) where TService : classParameters
Section titled “Parameters”kernel InstalledKernel
Returns
Section titled “Returns”TService
Type Parameters
Section titled “Type Parameters”TService
Invoke(MethodInfo?, object?[]?)
Section titled “ Invoke(MethodInfo?, object?[]?)”Whenever any method on the generated proxy type is called, this method is invoked to dispatch control.
protected override object? Invoke(MethodInfo? targetMethod, object?[]? args)Parameters
Section titled “Parameters”targetMethod MethodInfo?
The method the caller invoked.
args object?[]?
The arguments the caller passed to the method.
Returns
Section titled “Returns”The object to return to the caller, or null for void methods.