pub struct EmitContext<'a> {
pub stack: &'a Stack,
pub resource: &'a ResourceEntry,
pub resource_id: &'a str,
pub platform: Platform,
pub targets_kubernetes: bool,
pub stack_settings: &'a StackSettings,
pub names: &'a IndexMap<String, String>,
}Expand description
Context passed to generator-side import emitters.
Fields§
§stack: &'a StackThe source stack being rendered.
resource: &'a ResourceEntryThe stack resource entry currently being emitted.
resource_id: &'a strStable resource id for the current entry.
platform: PlatformTarget platform for this emission pass.
targets_kubernetes: boolWhether the artifact runs workloads on Kubernetes rather than on the cloud’s own compute.
platform names the cloud the cluster runs in, so it reads the same for an EKS package as
for a plain AWS one. Anything whose answer differs between the two — a resource skipped on
Kubernetes, and every expression that has to agree with that skip — needs this instead.
stack_settings: &'a StackSettingsUser-selected stack settings for the setup artifact.
names: &'a IndexMap<String, String>Stable names precomputed by the outer generator.
Implementations§
Trait Implementations§
Source§impl<'a> Clone for EmitContext<'a>
impl<'a> Clone for EmitContext<'a>
impl<'a> Copy for EmitContext<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for EmitContext<'a>
impl<'a> !UnwindSafe for EmitContext<'a>
impl<'a> Freeze for EmitContext<'a>
impl<'a> Send for EmitContext<'a>
impl<'a> Sync for EmitContext<'a>
impl<'a> Unpin for EmitContext<'a>
impl<'a> UnsafeUnpin for EmitContext<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more