sdf_metadata/
lib.rs

1#[cfg(any(feature = "host", feature = "guest"))]
2pub mod wit {
3    pub use bindings::sdf::metadata::*;
4    pub use bindings::exports::sdf::metadata as exports;
5
6    cfg_if::cfg_if! {
7      if #[cfg(feature = "host")] {
8        mod bindings {
9            wasmtime::component::bindgen!({
10                path: "wit/sdf.wit",
11                world: "dataflow-guest",
12                async: false,
13                trappable_imports: true,
14                additional_derives: [serde::Serialize, serde::Deserialize, Hash, PartialEq, Eq],
15            });
16        }
17    } else {
18        #[cfg(all(feature = "guest", not(feature = "host")))]
19        #[allow(dead_code)]
20        #[rustfmt::skip]
21        #[allow(clippy::all)]
22        mod bindings {
23            use wit_bindgen::generate;
24
25            generate!({
26                world: "dataflow-guest",
27                path: "wit",
28                additional_derives: [serde::Serialize, serde::Deserialize, Hash, PartialEq, Eq],
29            });
30        }
31    }
32    }
33}
34
35cfg_if::cfg_if! {
36    if #[cfg(any(feature = "host", feature = "guest"))] {
37        mod importer;
38        pub mod util;
39        pub mod metadata;
40
41        #[cfg(feature = "yaml")]
42        pub mod into_wit;
43    }
44}