PolywrapClient

class PolywrapClient(ffiClient: <Error class: unknown class>) : Invoker, Client, AutoCloseable

Constructors

Link copied to clipboard
constructor(ffiClient: <Error class: unknown class>)

Properties

Link copied to clipboard
val ffiInvoker: <Error class: unknown class>

Functions

Link copied to clipboard
open override fun close()
Link copied to clipboard
open override fun getEnvByUri(uri: Uri): Result<WrapEnv?>

Returns an env (a set of environmental variables) from the configuration used to instantiate the client.

Link copied to clipboard
open override fun getImplementations(uri: Uri): Result<List<Uri>>

Retrieves the list of implementation URIs for the specified interface URI.

Link copied to clipboard
open override fun getInterfaces(): Map<Uri, List<Uri>>?

Returns the interface implementations stored in the configuration.

Link copied to clipboard
inline fun <T, E, R> invoke(uri: Uri, method: String, args: T? = null, env: E, resolutionContext: <Error class: unknown class>? = null): InvokeResult<R>
inline fun <T, R> invoke(uri: Uri, method: String, args: T? = null, env: WrapEnv? = null, resolutionContext: <Error class: unknown class>? = null): InvokeResult<R>

Invokes the wrapper at the specified URI with the provided method and arguments of type T, and environment.

inline fun <R> invoke(uri: Uri, method: String, args: Map<String, Any?>? = null, env: WrapEnv? = null, resolutionContext: <Error class: unknown class>? = null): InvokeResult<R>

Invokes the wrapper at the specified URI with the provided method, arguments, and environment.

Link copied to clipboard
open override fun invokeRaw(uri: <Error class: unknown class>, method: String, args: List<UByte>?, env: List<UByte>?, resolutionContext: <Error class: unknown class>?): List<UByte>

Invokes the wrapper at the specified URI with the provided options.

open override fun invokeRaw(uri: Uri, method: String, args: ByteArray?, env: ByteArray?, resolutionContext: <Error class: unknown class>?): Result<ByteArray>

Invoke a wrapper. This method automatically retrieves and caches the wrapper.

Link copied to clipboard
open override fun invokeWrapperRaw(wrapper: Wrapper, uri: Uri, method: String, args: ByteArray?, env: ByteArray?, resolutionContext: <Error class: unknown class>?): Result<ByteArray>

Invoke a wrapper using an instance of the wrapper.

Link copied to clipboard
open override fun loadWrapper(uri: Uri, resolutionContext: <Error class: unknown class>?): Result<Wrapper>

Resolves the Wrapper at the specified URI.

Link copied to clipboard
open override fun tryResolveUri(uri: Uri, resolutionContext: <Error class: unknown class>?): Result<<Error class: unknown class>>

Try to resolve a URI to a URI, package or wrapper.