Package software.amazon.awscdk
Interface CfnOutputProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CfnOutputProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.116.0 (build 0eddcff)",
date="2025-10-29T11:15:30.876Z")
@Stability(Stable)
public interface CfnOutputProps
extends software.amazon.jsii.JsiiSerializable
Example:
Cluster cluster;
// add service account
ServiceAccount serviceAccount = cluster.addServiceAccount("MyServiceAccount");
Bucket bucket = new Bucket(this, "Bucket");
bucket.grantReadWrite(serviceAccount);
KubernetesManifest mypod = cluster.addManifest("mypod", Map.of(
"apiVersion", "v1",
"kind", "Pod",
"metadata", Map.of("name", "mypod"),
"spec", Map.of(
"serviceAccountName", serviceAccount.getServiceAccountName(),
"containers", List.of(Map.of(
"name", "hello",
"image", "paulbouwer/hello-kubernetes:1.5",
"ports", List.of(Map.of("containerPort", 8080)))))));
// create the resource after the service account.
mypod.node.addDependency(serviceAccount);
// print the IAM role arn for this service account
// print the IAM role arn for this service account
CfnOutput.Builder.create(this, "ServiceAccountIamRole").value(serviceAccount.getRole().getRoleArn()).build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCfnOutputPropsstatic final classAn implementation forCfnOutputProps -
Method Summary
Modifier and TypeMethodDescriptionstatic CfnOutputProps.Builderbuilder()default CfnConditionA condition to associate with this output value.default StringA String type that describes the output value.default StringThe name used to export the value of this output across stacks.default StringgetKey()The key of the property returned by aws cloudformation describe-stacks command.getValue()The value of the property returned by the aws cloudformation describe-stacks command.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getValue
The value of the property returned by the aws cloudformation describe-stacks command.The value of an output can include literals, parameter references, pseudo-parameters, a mapping value, or intrinsic functions.
-
getCondition
A condition to associate with this output value.If the condition evaluates to
false, this output value will not be included in the stack.Default: - No condition is associated with the output.
-
getDescription
A String type that describes the output value.The description can be a maximum of 4 K in length.
Default: - No description.
-
getExportName
The name used to export the value of this output across stacks.To import the value from another stack, use
Fn.importValue(exportName).Default: - the output is not exported
-
getKey
The key of the property returned by aws cloudformation describe-stacks command. -
builder
- Returns:
- a
CfnOutputProps.BuilderofCfnOutputProps
-