1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
//! The importer trait: turns a typed `ImportData` payload into a runtime
//! [`StackResourceState`].
//!
//! The trait lives here rather than next to the importers in `alien-infra`
//! so that code built for `wasm32-wasip1`, which cannot depend on
//! `alien-infra` and its cloud clients, can implement it.
use crate::;
use DeserializeOwned;
/// Generator-side typed payload → controller `StackResourceState` translator.
///
/// One impl per `(resource_type, cloud)` pair. Alien's own impls live at
/// `alien-infra/src/<resource>/<cloud>_import.rs` next to the controller so
/// `internal_state` stays in lock-step with the controller's state struct.