All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
software.aws.awsprototypingsdk.pipeline.SonarCodeScannerProps Maven / Gradle / Ivy
package software.aws.awsprototypingsdk.pipeline;
/**
* SonarCodeScanners properties.
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.71.0 (build f1f58ae)", date = "2022-12-16T05:48:51.195Z")
@software.amazon.jsii.Jsii(module = software.aws.awsprototypingsdk.$Module.class, fqn = "aws-prototyping-sdk.pipeline.SonarCodeScannerProps")
@software.amazon.jsii.Jsii.Proxy(SonarCodeScannerProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface SonarCodeScannerProps extends software.amazon.jsii.JsiiSerializable, software.aws.awsprototypingsdk.pipeline.SonarCodeScannerConfig {
/**
* S3 bucket ARN containing the built artifacts from the synth build.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getArtifactBucketArn();
/**
* ARN for the CodeBuild task responsible for executing the synth command.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@org.jetbrains.annotations.NotNull java.lang.String getSynthBuildArn();
/**
* Artifact bucket key ARN used to encrypt the artifacts.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
default @org.jetbrains.annotations.Nullable java.lang.String getArtifactBucketKeyArn() {
return null;
}
/**
* @return a {@link Builder} of {@link SonarCodeScannerProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link SonarCodeScannerProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public static final class Builder implements software.amazon.jsii.Builder {
java.lang.String artifactBucketArn;
java.lang.String synthBuildArn;
java.lang.String artifactBucketKeyArn;
java.lang.String sonarqubeAuthorizedGroup;
java.lang.String sonarqubeDefaultProfileOrGateName;
java.lang.String sonarqubeEndpoint;
java.lang.String sonarqubeProjectName;
java.lang.String cdkOutDir;
java.lang.String cfnNagIgnorePath;
java.util.List excludeGlobsForScan;
java.util.List includeGlobsForScan;
java.util.List preArchiveCommands;
java.lang.String sonarqubeSpecificProfileOrGateName;
java.util.List sonarqubeTags;
/**
* Sets the value of {@link SonarCodeScannerProps#getArtifactBucketArn}
* @param artifactBucketArn S3 bucket ARN containing the built artifacts from the synth build. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder artifactBucketArn(java.lang.String artifactBucketArn) {
this.artifactBucketArn = artifactBucketArn;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSynthBuildArn}
* @param synthBuildArn ARN for the CodeBuild task responsible for executing the synth command. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder synthBuildArn(java.lang.String synthBuildArn) {
this.synthBuildArn = synthBuildArn;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getArtifactBucketKeyArn}
* @param artifactBucketKeyArn Artifact bucket key ARN used to encrypt the artifacts.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder artifactBucketKeyArn(java.lang.String artifactBucketKeyArn) {
this.artifactBucketKeyArn = artifactBucketKeyArn;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeAuthorizedGroup}
* @param sonarqubeAuthorizedGroup Group name in Sonarqube with access to administer this project. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeAuthorizedGroup(java.lang.String sonarqubeAuthorizedGroup) {
this.sonarqubeAuthorizedGroup = sonarqubeAuthorizedGroup;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeDefaultProfileOrGateName}
* @param sonarqubeDefaultProfileOrGateName Default profile/gate name i.e: your org profile. This parameter is required.
* Note: These need to be set up in Sonarqube manually.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeDefaultProfileOrGateName(java.lang.String sonarqubeDefaultProfileOrGateName) {
this.sonarqubeDefaultProfileOrGateName = sonarqubeDefaultProfileOrGateName;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeEndpoint}
* @param sonarqubeEndpoint endpoint of the sonarqube instance i.e: https://. This parameter is required.
* Note: Ensure a trailing '/' is not included.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeEndpoint(java.lang.String sonarqubeEndpoint) {
this.sonarqubeEndpoint = sonarqubeEndpoint;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeProjectName}
* @param sonarqubeProjectName Name of the project to create in Sonarqube. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeProjectName(java.lang.String sonarqubeProjectName) {
this.sonarqubeProjectName = sonarqubeProjectName;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getCdkOutDir}
* @param cdkOutDir directory containing the synthesized cdk resources.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder cdkOutDir(java.lang.String cdkOutDir) {
this.cdkOutDir = cdkOutDir;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getCfnNagIgnorePath}
* @param cfnNagIgnorePath path to a file containing the cfn nag suppression rules.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder cfnNagIgnorePath(java.lang.String cfnNagIgnorePath) {
this.cfnNagIgnorePath = cfnNagIgnorePath;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getExcludeGlobsForScan}
* @param excludeGlobsForScan glob patterns to exclude from sonar scan.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder excludeGlobsForScan(java.util.List excludeGlobsForScan) {
this.excludeGlobsForScan = excludeGlobsForScan;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getIncludeGlobsForScan}
* @param includeGlobsForScan glob patterns to include from sonar scan.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder includeGlobsForScan(java.util.List includeGlobsForScan) {
this.includeGlobsForScan = includeGlobsForScan;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getPreArchiveCommands}
* @param preArchiveCommands Hook which allows custom commands to be executed before the process commences the archival process.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder preArchiveCommands(java.util.List preArchiveCommands) {
this.preArchiveCommands = preArchiveCommands;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeSpecificProfileOrGateName}
* @param sonarqubeSpecificProfileOrGateName Specific profile/gate name i.e: language specific.
* Note: These need to be set up in Sonarqube manually.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeSpecificProfileOrGateName(java.lang.String sonarqubeSpecificProfileOrGateName) {
this.sonarqubeSpecificProfileOrGateName = sonarqubeSpecificProfileOrGateName;
return this;
}
/**
* Sets the value of {@link SonarCodeScannerProps#getSonarqubeTags}
* @param sonarqubeTags Tags to associate with this project.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public Builder sonarqubeTags(java.util.List sonarqubeTags) {
this.sonarqubeTags = sonarqubeTags;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link SonarCodeScannerProps}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@Override
public SonarCodeScannerProps build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link SonarCodeScannerProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements SonarCodeScannerProps {
private final java.lang.String artifactBucketArn;
private final java.lang.String synthBuildArn;
private final java.lang.String artifactBucketKeyArn;
private final java.lang.String sonarqubeAuthorizedGroup;
private final java.lang.String sonarqubeDefaultProfileOrGateName;
private final java.lang.String sonarqubeEndpoint;
private final java.lang.String sonarqubeProjectName;
private final java.lang.String cdkOutDir;
private final java.lang.String cfnNagIgnorePath;
private final java.util.List excludeGlobsForScan;
private final java.util.List includeGlobsForScan;
private final java.util.List preArchiveCommands;
private final java.lang.String sonarqubeSpecificProfileOrGateName;
private final java.util.List sonarqubeTags;
/**
* 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.artifactBucketArn = software.amazon.jsii.Kernel.get(this, "artifactBucketArn", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.synthBuildArn = software.amazon.jsii.Kernel.get(this, "synthBuildArn", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.artifactBucketKeyArn = software.amazon.jsii.Kernel.get(this, "artifactBucketKeyArn", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.sonarqubeAuthorizedGroup = software.amazon.jsii.Kernel.get(this, "sonarqubeAuthorizedGroup", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.sonarqubeDefaultProfileOrGateName = software.amazon.jsii.Kernel.get(this, "sonarqubeDefaultProfileOrGateName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.sonarqubeEndpoint = software.amazon.jsii.Kernel.get(this, "sonarqubeEndpoint", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.sonarqubeProjectName = software.amazon.jsii.Kernel.get(this, "sonarqubeProjectName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.cdkOutDir = software.amazon.jsii.Kernel.get(this, "cdkOutDir", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.cfnNagIgnorePath = software.amazon.jsii.Kernel.get(this, "cfnNagIgnorePath", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.excludeGlobsForScan = software.amazon.jsii.Kernel.get(this, "excludeGlobsForScan", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class)));
this.includeGlobsForScan = software.amazon.jsii.Kernel.get(this, "includeGlobsForScan", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class)));
this.preArchiveCommands = software.amazon.jsii.Kernel.get(this, "preArchiveCommands", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class)));
this.sonarqubeSpecificProfileOrGateName = software.amazon.jsii.Kernel.get(this, "sonarqubeSpecificProfileOrGateName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.sonarqubeTags = software.amazon.jsii.Kernel.get(this, "sonarqubeTags", software.amazon.jsii.NativeType.listOf(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.artifactBucketArn = java.util.Objects.requireNonNull(builder.artifactBucketArn, "artifactBucketArn is required");
this.synthBuildArn = java.util.Objects.requireNonNull(builder.synthBuildArn, "synthBuildArn is required");
this.artifactBucketKeyArn = builder.artifactBucketKeyArn;
this.sonarqubeAuthorizedGroup = java.util.Objects.requireNonNull(builder.sonarqubeAuthorizedGroup, "sonarqubeAuthorizedGroup is required");
this.sonarqubeDefaultProfileOrGateName = java.util.Objects.requireNonNull(builder.sonarqubeDefaultProfileOrGateName, "sonarqubeDefaultProfileOrGateName is required");
this.sonarqubeEndpoint = java.util.Objects.requireNonNull(builder.sonarqubeEndpoint, "sonarqubeEndpoint is required");
this.sonarqubeProjectName = java.util.Objects.requireNonNull(builder.sonarqubeProjectName, "sonarqubeProjectName is required");
this.cdkOutDir = builder.cdkOutDir;
this.cfnNagIgnorePath = builder.cfnNagIgnorePath;
this.excludeGlobsForScan = builder.excludeGlobsForScan;
this.includeGlobsForScan = builder.includeGlobsForScan;
this.preArchiveCommands = builder.preArchiveCommands;
this.sonarqubeSpecificProfileOrGateName = builder.sonarqubeSpecificProfileOrGateName;
this.sonarqubeTags = builder.sonarqubeTags;
}
@Override
public final java.lang.String getArtifactBucketArn() {
return this.artifactBucketArn;
}
@Override
public final java.lang.String getSynthBuildArn() {
return this.synthBuildArn;
}
@Override
public final java.lang.String getArtifactBucketKeyArn() {
return this.artifactBucketKeyArn;
}
@Override
public final java.lang.String getSonarqubeAuthorizedGroup() {
return this.sonarqubeAuthorizedGroup;
}
@Override
public final java.lang.String getSonarqubeDefaultProfileOrGateName() {
return this.sonarqubeDefaultProfileOrGateName;
}
@Override
public final java.lang.String getSonarqubeEndpoint() {
return this.sonarqubeEndpoint;
}
@Override
public final java.lang.String getSonarqubeProjectName() {
return this.sonarqubeProjectName;
}
@Override
public final java.lang.String getCdkOutDir() {
return this.cdkOutDir;
}
@Override
public final java.lang.String getCfnNagIgnorePath() {
return this.cfnNagIgnorePath;
}
@Override
public final java.util.List getExcludeGlobsForScan() {
return this.excludeGlobsForScan;
}
@Override
public final java.util.List getIncludeGlobsForScan() {
return this.includeGlobsForScan;
}
@Override
public final java.util.List getPreArchiveCommands() {
return this.preArchiveCommands;
}
@Override
public final java.lang.String getSonarqubeSpecificProfileOrGateName() {
return this.sonarqubeSpecificProfileOrGateName;
}
@Override
public final java.util.List getSonarqubeTags() {
return this.sonarqubeTags;
}
@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("artifactBucketArn", om.valueToTree(this.getArtifactBucketArn()));
data.set("synthBuildArn", om.valueToTree(this.getSynthBuildArn()));
if (this.getArtifactBucketKeyArn() != null) {
data.set("artifactBucketKeyArn", om.valueToTree(this.getArtifactBucketKeyArn()));
}
data.set("sonarqubeAuthorizedGroup", om.valueToTree(this.getSonarqubeAuthorizedGroup()));
data.set("sonarqubeDefaultProfileOrGateName", om.valueToTree(this.getSonarqubeDefaultProfileOrGateName()));
data.set("sonarqubeEndpoint", om.valueToTree(this.getSonarqubeEndpoint()));
data.set("sonarqubeProjectName", om.valueToTree(this.getSonarqubeProjectName()));
if (this.getCdkOutDir() != null) {
data.set("cdkOutDir", om.valueToTree(this.getCdkOutDir()));
}
if (this.getCfnNagIgnorePath() != null) {
data.set("cfnNagIgnorePath", om.valueToTree(this.getCfnNagIgnorePath()));
}
if (this.getExcludeGlobsForScan() != null) {
data.set("excludeGlobsForScan", om.valueToTree(this.getExcludeGlobsForScan()));
}
if (this.getIncludeGlobsForScan() != null) {
data.set("includeGlobsForScan", om.valueToTree(this.getIncludeGlobsForScan()));
}
if (this.getPreArchiveCommands() != null) {
data.set("preArchiveCommands", om.valueToTree(this.getPreArchiveCommands()));
}
if (this.getSonarqubeSpecificProfileOrGateName() != null) {
data.set("sonarqubeSpecificProfileOrGateName", om.valueToTree(this.getSonarqubeSpecificProfileOrGateName()));
}
if (this.getSonarqubeTags() != null) {
data.set("sonarqubeTags", om.valueToTree(this.getSonarqubeTags()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("aws-prototyping-sdk.pipeline.SonarCodeScannerProps"));
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;
SonarCodeScannerProps.Jsii$Proxy that = (SonarCodeScannerProps.Jsii$Proxy) o;
if (!artifactBucketArn.equals(that.artifactBucketArn)) return false;
if (!synthBuildArn.equals(that.synthBuildArn)) return false;
if (this.artifactBucketKeyArn != null ? !this.artifactBucketKeyArn.equals(that.artifactBucketKeyArn) : that.artifactBucketKeyArn != null) return false;
if (!sonarqubeAuthorizedGroup.equals(that.sonarqubeAuthorizedGroup)) return false;
if (!sonarqubeDefaultProfileOrGateName.equals(that.sonarqubeDefaultProfileOrGateName)) return false;
if (!sonarqubeEndpoint.equals(that.sonarqubeEndpoint)) return false;
if (!sonarqubeProjectName.equals(that.sonarqubeProjectName)) return false;
if (this.cdkOutDir != null ? !this.cdkOutDir.equals(that.cdkOutDir) : that.cdkOutDir != null) return false;
if (this.cfnNagIgnorePath != null ? !this.cfnNagIgnorePath.equals(that.cfnNagIgnorePath) : that.cfnNagIgnorePath != null) return false;
if (this.excludeGlobsForScan != null ? !this.excludeGlobsForScan.equals(that.excludeGlobsForScan) : that.excludeGlobsForScan != null) return false;
if (this.includeGlobsForScan != null ? !this.includeGlobsForScan.equals(that.includeGlobsForScan) : that.includeGlobsForScan != null) return false;
if (this.preArchiveCommands != null ? !this.preArchiveCommands.equals(that.preArchiveCommands) : that.preArchiveCommands != null) return false;
if (this.sonarqubeSpecificProfileOrGateName != null ? !this.sonarqubeSpecificProfileOrGateName.equals(that.sonarqubeSpecificProfileOrGateName) : that.sonarqubeSpecificProfileOrGateName != null) return false;
return this.sonarqubeTags != null ? this.sonarqubeTags.equals(that.sonarqubeTags) : that.sonarqubeTags == null;
}
@Override
public final int hashCode() {
int result = this.artifactBucketArn.hashCode();
result = 31 * result + (this.synthBuildArn.hashCode());
result = 31 * result + (this.artifactBucketKeyArn != null ? this.artifactBucketKeyArn.hashCode() : 0);
result = 31 * result + (this.sonarqubeAuthorizedGroup.hashCode());
result = 31 * result + (this.sonarqubeDefaultProfileOrGateName.hashCode());
result = 31 * result + (this.sonarqubeEndpoint.hashCode());
result = 31 * result + (this.sonarqubeProjectName.hashCode());
result = 31 * result + (this.cdkOutDir != null ? this.cdkOutDir.hashCode() : 0);
result = 31 * result + (this.cfnNagIgnorePath != null ? this.cfnNagIgnorePath.hashCode() : 0);
result = 31 * result + (this.excludeGlobsForScan != null ? this.excludeGlobsForScan.hashCode() : 0);
result = 31 * result + (this.includeGlobsForScan != null ? this.includeGlobsForScan.hashCode() : 0);
result = 31 * result + (this.preArchiveCommands != null ? this.preArchiveCommands.hashCode() : 0);
result = 31 * result + (this.sonarqubeSpecificProfileOrGateName != null ? this.sonarqubeSpecificProfileOrGateName.hashCode() : 0);
result = 31 * result + (this.sonarqubeTags != null ? this.sonarqubeTags.hashCode() : 0);
return result;
}
}
}