Class WasiContextBuilder

java.lang.Object
ai.tegmentum.wasmtime4j.wasi.AbstractWasiContextBuilder<WasiContextBuilder>
ai.tegmentum.wasmtime4j.panama.wasi.WasiContextBuilder

public final class WasiContextBuilder extends ai.tegmentum.wasmtime4j.wasi.AbstractWasiContextBuilder<WasiContextBuilder>
Panama implementation of the WASI context builder.

This builder provides a fluent API for configuring WASI contexts using Panama Foreign Function Interface bindings to the native Wasmtime library.

Since:
1.0.0
  • Method Summary

    Modifier and Type
    Method
    Description
    Creates a WASI context with the configured settings.

    Methods inherited from class ai.tegmentum.wasmtime4j.wasi.AbstractWasiContextBuilder

    convertEnvironmentToArray, convertPreopenDirectoriesToArray, getArguments, getEnvironment, getInsecureRandomSeed, getPreopenedDirectories, getWorkingDirectory, isAllowBlockingCurrentThread, isAllowIpNameLookup, isAllowNetwork, isAllowTcp, isAllowUdp, validateConfiguration, withAllowBlockingCurrentThread, withAllowIpNameLookup, withAllowNetwork, withAllowTcp, withAllowUdp, withArgument, withArguments, withEnvironment, withEnvironment, withInheritedEnvironment, withInsecureRandomSeed, withPreopenDirectory, withPreopenDirectory, withWorkingDirectory

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • build

      public WasiContext build()
      Creates a WASI context with the configured settings.
      Returns:
      the configured WASI context
      Throws:
      RuntimeException - if the WASI context cannot be created