Struct spin_core::StoreBuilder

source ·
pub struct StoreBuilder { /* private fields */ }
Expand description

A builder interface for configuring a new Store.

A new StoreBuilder can be obtained with crate::Engine::store_builder.

Implementations§

Sets a maximum memory allocation limit.

See wasmtime::ResourceLimiter::memory_growing (maximum) for details on how this limit is enforced.

Inherit stdin from the host process.

Sets the WASI stdin descriptor.

Sets the WASI stdin descriptor to the given Reader.

Inherit stdin from the host process.

Sets the WASI stdout descriptor.

Sets the WASI stdout descriptor to the given Writeer.

Sets the WASI stdout descriptor to an in-memory buffer which can be retrieved after execution from the returned OutputBuffer.

Inherit stdin from the host process.

Sets the WASI stderr descriptor.

Sets the WASI stderr descriptor to the given Writeer.

Sets the WASI stderr descriptor to an in-memory buffer which can be retrieved after execution from the returned OutputBuffer.

Appends the given strings to the the WASI ‘args’.

Sets the given key/value string entries on the the WASI ‘env’.

“Mounts” the given host_path into the WASI filesystem at the given guest_path with read-only capabilities.

“Mounts” the given host_path into the WASI filesystem at the given guest_path with read and write capabilities.

Returns a mutable reference to the built

Builds a Store from this builder with given host state data.

If T: Default, it may be preferable to use StoreBuilder::build.

Builds a Store from this builder with Default host state data.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Query the “status” flags for the self file descriptor.
Create a new SetFdFlags value for use with set_fd_flags. Read more
Set the “status” flags for the self file descriptor. Read more
Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more