io.github.hsiehshujeng.cdk.databrew.cicd.DataBrewCodePipelineProps Maven / Gradle / Ivy
Show all versions of cdk-databrew-cicd Show documentation
package io.github.hsiehshujeng.cdk.databrew.cicd;
/**
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.105.0 (build 0a2adcb)", date = "2024-11-18T01:03:07.203Z")
@software.amazon.jsii.Jsii(module = io.github.hsiehshujeng.cdk.databrew.cicd.$Module.class, fqn = "cdk-databrew-cicd.DataBrewCodePipelineProps")
@software.amazon.jsii.Jsii.Proxy(DataBrewCodePipelineProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface DataBrewCodePipelineProps extends software.amazon.jsii.JsiiSerializable {
/**
* The ARN of the IAM role in the pre-production account.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getPreproductionIamRoleArn();
/**
* The ARN of the IAM role in the production account.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getProductionIamRoleArn();
/**
* The name of the branch that will trigger the DataBrew CICD pipeline.
*
* Default: 'main'
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getBranchName() {
return null;
}
/**
* The name of the S3 bucket for the CodePipeline DataBrew CICD pipeline.
*
* Default: 'databrew-cicd-codepipelineartifactstorebucket'
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getBucketName() {
return null;
}
/**
* the (required) name of the Artifact at the first stage.
*
* Default: 'SourceOutput'
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getFirstStageArtifactName() {
return null;
}
/**
* The name of the CodePipeline Databrew CICD pipeline.
*
* Default: 'DataBrew-Recipe-Application'
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getPipelineName() {
return null;
}
/**
* The name of the CodeCommit repositroy for the DataBrew CICD pipeline.
*
* Default: 'DataBrew-Recipes-Repo'
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getRepoName() {
return null;
}
/**
* @return a {@link Builder} of {@link DataBrewCodePipelineProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link DataBrewCodePipelineProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public static final class Builder implements software.amazon.jsii.Builder {
java.lang.String preproductionIamRoleArn;
java.lang.String productionIamRoleArn;
java.lang.String branchName;
java.lang.String bucketName;
java.lang.String firstStageArtifactName;
java.lang.String pipelineName;
java.lang.String repoName;
/**
* Sets the value of {@link DataBrewCodePipelineProps#getPreproductionIamRoleArn}
* @param preproductionIamRoleArn The ARN of the IAM role in the pre-production account. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder preproductionIamRoleArn(java.lang.String preproductionIamRoleArn) {
this.preproductionIamRoleArn = preproductionIamRoleArn;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getProductionIamRoleArn}
* @param productionIamRoleArn The ARN of the IAM role in the production account. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder productionIamRoleArn(java.lang.String productionIamRoleArn) {
this.productionIamRoleArn = productionIamRoleArn;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getBranchName}
* @param branchName The name of the branch that will trigger the DataBrew CICD pipeline.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder branchName(java.lang.String branchName) {
this.branchName = branchName;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getBucketName}
* @param bucketName The name of the S3 bucket for the CodePipeline DataBrew CICD pipeline.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder bucketName(java.lang.String bucketName) {
this.bucketName = bucketName;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getFirstStageArtifactName}
* @param firstStageArtifactName the (required) name of the Artifact at the first stage.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder firstStageArtifactName(java.lang.String firstStageArtifactName) {
this.firstStageArtifactName = firstStageArtifactName;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getPipelineName}
* @param pipelineName The name of the CodePipeline Databrew CICD pipeline.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder pipelineName(java.lang.String pipelineName) {
this.pipelineName = pipelineName;
return this;
}
/**
* Sets the value of {@link DataBrewCodePipelineProps#getRepoName}
* @param repoName The name of the CodeCommit repositroy for the DataBrew CICD pipeline.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder repoName(java.lang.String repoName) {
this.repoName = repoName;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link DataBrewCodePipelineProps}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@Override
public DataBrewCodePipelineProps build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link DataBrewCodePipelineProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements DataBrewCodePipelineProps {
private final java.lang.String preproductionIamRoleArn;
private final java.lang.String productionIamRoleArn;
private final java.lang.String branchName;
private final java.lang.String bucketName;
private final java.lang.String firstStageArtifactName;
private final java.lang.String pipelineName;
private final java.lang.String repoName;
/**
* Constructor that initializes the object based on values retrieved from the JsiiObject.
* @param objRef Reference to the JSII managed object.
*/
protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) {
super(objRef);
this.preproductionIamRoleArn = software.amazon.jsii.Kernel.get(this, "preproductionIamRoleArn", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.productionIamRoleArn = software.amazon.jsii.Kernel.get(this, "productionIamRoleArn", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.branchName = software.amazon.jsii.Kernel.get(this, "branchName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.bucketName = software.amazon.jsii.Kernel.get(this, "bucketName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.firstStageArtifactName = software.amazon.jsii.Kernel.get(this, "firstStageArtifactName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.pipelineName = software.amazon.jsii.Kernel.get(this, "pipelineName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.repoName = software.amazon.jsii.Kernel.get(this, "repoName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
}
/**
* Constructor that initializes the object based on literal property values passed by the {@link Builder}.
*/
protected Jsii$Proxy(final Builder builder) {
super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
this.preproductionIamRoleArn = java.util.Objects.requireNonNull(builder.preproductionIamRoleArn, "preproductionIamRoleArn is required");
this.productionIamRoleArn = java.util.Objects.requireNonNull(builder.productionIamRoleArn, "productionIamRoleArn is required");
this.branchName = builder.branchName;
this.bucketName = builder.bucketName;
this.firstStageArtifactName = builder.firstStageArtifactName;
this.pipelineName = builder.pipelineName;
this.repoName = builder.repoName;
}
@Override
public final java.lang.String getPreproductionIamRoleArn() {
return this.preproductionIamRoleArn;
}
@Override
public final java.lang.String getProductionIamRoleArn() {
return this.productionIamRoleArn;
}
@Override
public final java.lang.String getBranchName() {
return this.branchName;
}
@Override
public final java.lang.String getBucketName() {
return this.bucketName;
}
@Override
public final java.lang.String getFirstStageArtifactName() {
return this.firstStageArtifactName;
}
@Override
public final java.lang.String getPipelineName() {
return this.pipelineName;
}
@Override
public final java.lang.String getRepoName() {
return this.repoName;
}
@Override
@software.amazon.jsii.Internal
public com.fasterxml.jackson.databind.JsonNode $jsii$toJson() {
final com.fasterxml.jackson.databind.ObjectMapper om = software.amazon.jsii.JsiiObjectMapper.INSTANCE;
final com.fasterxml.jackson.databind.node.ObjectNode data = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
data.set("preproductionIamRoleArn", om.valueToTree(this.getPreproductionIamRoleArn()));
data.set("productionIamRoleArn", om.valueToTree(this.getProductionIamRoleArn()));
if (this.getBranchName() != null) {
data.set("branchName", om.valueToTree(this.getBranchName()));
}
if (this.getBucketName() != null) {
data.set("bucketName", om.valueToTree(this.getBucketName()));
}
if (this.getFirstStageArtifactName() != null) {
data.set("firstStageArtifactName", om.valueToTree(this.getFirstStageArtifactName()));
}
if (this.getPipelineName() != null) {
data.set("pipelineName", om.valueToTree(this.getPipelineName()));
}
if (this.getRepoName() != null) {
data.set("repoName", om.valueToTree(this.getRepoName()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("cdk-databrew-cicd.DataBrewCodePipelineProps"));
struct.set("data", data);
final com.fasterxml.jackson.databind.node.ObjectNode obj = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
obj.set("$jsii.struct", struct);
return obj;
}
@Override
public final boolean equals(final Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
DataBrewCodePipelineProps.Jsii$Proxy that = (DataBrewCodePipelineProps.Jsii$Proxy) o;
if (!preproductionIamRoleArn.equals(that.preproductionIamRoleArn)) return false;
if (!productionIamRoleArn.equals(that.productionIamRoleArn)) return false;
if (this.branchName != null ? !this.branchName.equals(that.branchName) : that.branchName != null) return false;
if (this.bucketName != null ? !this.bucketName.equals(that.bucketName) : that.bucketName != null) return false;
if (this.firstStageArtifactName != null ? !this.firstStageArtifactName.equals(that.firstStageArtifactName) : that.firstStageArtifactName != null) return false;
if (this.pipelineName != null ? !this.pipelineName.equals(that.pipelineName) : that.pipelineName != null) return false;
return this.repoName != null ? this.repoName.equals(that.repoName) : that.repoName == null;
}
@Override
public final int hashCode() {
int result = this.preproductionIamRoleArn.hashCode();
result = 31 * result + (this.productionIamRoleArn.hashCode());
result = 31 * result + (this.branchName != null ? this.branchName.hashCode() : 0);
result = 31 * result + (this.bucketName != null ? this.bucketName.hashCode() : 0);
result = 31 * result + (this.firstStageArtifactName != null ? this.firstStageArtifactName.hashCode() : 0);
result = 31 * result + (this.pipelineName != null ? this.pipelineName.hashCode() : 0);
result = 31 * result + (this.repoName != null ? this.repoName.hashCode() : 0);
return result;
}
}
}