Crate wit_bindgen

Crate wit_bindgen 

Source
Expand description

Bindings generation support for Rust with the Component Model.

This crate is a bindings generator for WIT and the Component Model. Users are likely interested in the generate! macro which actually generates bindings. Otherwise this crate provides any runtime support necessary for the macro-generated code.

Modules§

examplesdocsrs
Examples of output of the generate! macro.

Macros§

generatemacros
Generate bindings for an input WIT document.

Structs§

AbiBufferasync
A helper structure used with a stream to handle the canonical ABI representation of lists and track partial writes.
FutureReadasync
Represents a read operation which may be cancelled prior to completion.
FutureReaderasync
Represents the readable end of a Component Model future<T>.
FutureWriteasync
Represents a write operation which may be cancelled prior to completion.
FutureWriteErrorasync
Error type in the result of FutureWrite, or the error type that is a result of a failure to write a future.
FutureWriterasync
Represents the writable end of a Component Model future.
StreamReadasync
Represents a read operation which may be cancelled prior to completion.
StreamReaderasync
Represents the readable end of a Component Model stream.
StreamWriteasync
Represents a write operation which may be cancelled prior to completion.
StreamWriterasync
Represents the writable end of a Component Model stream.

Enums§

FutureWriteCancelasync
Result of FutureWrite::cancel.
StreamResultasync
Result of a StreamWriter::write or StreamReader::read operation, yielded by the StreamWrite or StreamRead futures.

Functions§

backpressure_decasync
Call the backpressure.dec canonical built-in function.
backpressure_incasync
Call the backpressure.inc canonical built-in function.
backpressure_setDeprecatedasync
Call the backpressure.set canonical built-in function.
block_onasync
Run the specified future to completion, returning the result.
spawnasync-spawn
Spawn the provided future to get executed concurrently with the currently-running async computation.
yield_asyncasync
The asynchronous counterpart to yield_blocking.
yield_blockingasync
Call the yield canonical built-in function.