io.github.cdklabs.cdk.cicd.wrapper.CodeArtifactPluginProps Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cdk-cicd-wrapper Show documentation
Show all versions of cdk-cicd-wrapper Show documentation
This repository contains the infrastructure as code to wrap your AWS CDK project with CI/CD around it.
package io.github.cdklabs.cdk.cicd.wrapper;
/**
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.103.1 (build bef2dea)", date = "2024-09-03T16:35:59.276Z")
@software.amazon.jsii.Jsii(module = io.github.cdklabs.cdk.cicd.wrapper.$Module.class, fqn = "@cdklabs/cdk-cicd-wrapper.CodeArtifactPluginProps")
@software.amazon.jsii.Jsii.Proxy(CodeArtifactPluginProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface CodeArtifactPluginProps extends software.amazon.jsii.JsiiSerializable {
/**
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getDomain();
/**
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getRepositoryName();
/**
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getAccount() {
return null;
}
/**
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getNpmScope() {
return null;
}
/**
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.util.List getRepositoryTypes() {
return null;
}
/**
* @return a {@link Builder} of {@link CodeArtifactPluginProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link CodeArtifactPluginProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public static final class Builder implements software.amazon.jsii.Builder {
java.lang.String domain;
java.lang.String repositoryName;
java.lang.String account;
java.lang.String npmScope;
java.util.List repositoryTypes;
/**
* Sets the value of {@link CodeArtifactPluginProps#getDomain}
* @param domain the value to be set. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder domain(java.lang.String domain) {
this.domain = domain;
return this;
}
/**
* Sets the value of {@link CodeArtifactPluginProps#getRepositoryName}
* @param repositoryName the value to be set. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder repositoryName(java.lang.String repositoryName) {
this.repositoryName = repositoryName;
return this;
}
/**
* Sets the value of {@link CodeArtifactPluginProps#getAccount}
* @param account the value to be set.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder account(java.lang.String account) {
this.account = account;
return this;
}
/**
* Sets the value of {@link CodeArtifactPluginProps#getNpmScope}
* @param npmScope the value to be set.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder npmScope(java.lang.String npmScope) {
this.npmScope = npmScope;
return this;
}
/**
* Sets the value of {@link CodeArtifactPluginProps#getRepositoryTypes}
* @param repositoryTypes the value to be set.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@SuppressWarnings("unchecked")
public Builder repositoryTypes(java.util.List extends io.github.cdklabs.cdk.cicd.wrapper.CodeArtifactRepositoryTypes> repositoryTypes) {
this.repositoryTypes = (java.util.List)repositoryTypes;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link CodeArtifactPluginProps}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@Override
public CodeArtifactPluginProps build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link CodeArtifactPluginProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements CodeArtifactPluginProps {
private final java.lang.String domain;
private final java.lang.String repositoryName;
private final java.lang.String account;
private final java.lang.String npmScope;
private final java.util.List repositoryTypes;
/**
* 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.domain = software.amazon.jsii.Kernel.get(this, "domain", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.repositoryName = software.amazon.jsii.Kernel.get(this, "repositoryName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.account = software.amazon.jsii.Kernel.get(this, "account", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.npmScope = software.amazon.jsii.Kernel.get(this, "npmScope", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.repositoryTypes = software.amazon.jsii.Kernel.get(this, "repositoryTypes", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(io.github.cdklabs.cdk.cicd.wrapper.CodeArtifactRepositoryTypes.class)));
}
/**
* Constructor that initializes the object based on literal property values passed by the {@link Builder}.
*/
@SuppressWarnings("unchecked")
protected Jsii$Proxy(final Builder builder) {
super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
this.domain = java.util.Objects.requireNonNull(builder.domain, "domain is required");
this.repositoryName = java.util.Objects.requireNonNull(builder.repositoryName, "repositoryName is required");
this.account = builder.account;
this.npmScope = builder.npmScope;
this.repositoryTypes = (java.util.List)builder.repositoryTypes;
}
@Override
public final java.lang.String getDomain() {
return this.domain;
}
@Override
public final java.lang.String getRepositoryName() {
return this.repositoryName;
}
@Override
public final java.lang.String getAccount() {
return this.account;
}
@Override
public final java.lang.String getNpmScope() {
return this.npmScope;
}
@Override
public final java.util.List getRepositoryTypes() {
return this.repositoryTypes;
}
@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("domain", om.valueToTree(this.getDomain()));
data.set("repositoryName", om.valueToTree(this.getRepositoryName()));
if (this.getAccount() != null) {
data.set("account", om.valueToTree(this.getAccount()));
}
if (this.getNpmScope() != null) {
data.set("npmScope", om.valueToTree(this.getNpmScope()));
}
if (this.getRepositoryTypes() != null) {
data.set("repositoryTypes", om.valueToTree(this.getRepositoryTypes()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("@cdklabs/cdk-cicd-wrapper.CodeArtifactPluginProps"));
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;
CodeArtifactPluginProps.Jsii$Proxy that = (CodeArtifactPluginProps.Jsii$Proxy) o;
if (!domain.equals(that.domain)) return false;
if (!repositoryName.equals(that.repositoryName)) return false;
if (this.account != null ? !this.account.equals(that.account) : that.account != null) return false;
if (this.npmScope != null ? !this.npmScope.equals(that.npmScope) : that.npmScope != null) return false;
return this.repositoryTypes != null ? this.repositoryTypes.equals(that.repositoryTypes) : that.repositoryTypes == null;
}
@Override
public final int hashCode() {
int result = this.domain.hashCode();
result = 31 * result + (this.repositoryName.hashCode());
result = 31 * result + (this.account != null ? this.account.hashCode() : 0);
result = 31 * result + (this.npmScope != null ? this.npmScope.hashCode() : 0);
result = 31 * result + (this.repositoryTypes != null ? this.repositoryTypes.hashCode() : 0);
return result;
}
}
}