All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.aws.awsprototypingsdk.nxmonorepo.VersionGroup Maven / Gradle / Ivy

There is a newer version: 0.19.68
Show newest version
package software.aws.awsprototypingsdk.nxmonorepo;

/**
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.82.0 (build 2d2ddd7)", date = "2023-08-03T02:16:17.270Z")
@software.amazon.jsii.Jsii(module = software.aws.awsprototypingsdk.nxmonorepo.$Module.class, fqn = "@aws-prototyping-sdk/nx-monorepo.VersionGroup")
@software.amazon.jsii.Jsii.Proxy(VersionGroup.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface VersionGroup extends software.amazon.jsii.JsiiSerializable {

    /**
     * the names of the dependencies (eg.
     * 

* "lodash") which belong to this group */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @org.jetbrains.annotations.NotNull java.util.List getDependencies(); /** * the names of packages in your monorepo which belong to this group, taken from the "name" field in package.json, not the package directory name. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @org.jetbrains.annotations.NotNull java.util.List getPackages(); /** * optionally only apply this group to dependencies of the provided types. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.util.List getDependencyTypes() { return null; } /** * optionally force all dependencies in this group to be removed. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.Boolean getIsBanned() { return null; } /** * optionally force all dependencies in this group to have this version. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.String getPinVersion() { return null; } /** * @return a {@link Builder} of {@link VersionGroup} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) static Builder builder() { return new Builder(); } /** * A builder for {@link VersionGroup} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static final class Builder implements software.amazon.jsii.Builder { java.util.List dependencies; java.util.List packages; java.util.List dependencyTypes; java.lang.Boolean isBanned; java.lang.String pinVersion; /** * Sets the value of {@link VersionGroup#getDependencies} * @param dependencies the names of the dependencies (eg. This parameter is required. * "lodash") which belong to this group * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder dependencies(java.util.List dependencies) { this.dependencies = dependencies; return this; } /** * Sets the value of {@link VersionGroup#getPackages} * @param packages the names of packages in your monorepo which belong to this group, taken from the "name" field in package.json, not the package directory name. This parameter is required. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder packages(java.util.List packages) { this.packages = packages; return this; } /** * Sets the value of {@link VersionGroup#getDependencyTypes} * @param dependencyTypes optionally only apply this group to dependencies of the provided types. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder dependencyTypes(java.util.List dependencyTypes) { this.dependencyTypes = dependencyTypes; return this; } /** * Sets the value of {@link VersionGroup#getIsBanned} * @param isBanned optionally force all dependencies in this group to be removed. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder isBanned(java.lang.Boolean isBanned) { this.isBanned = isBanned; return this; } /** * Sets the value of {@link VersionGroup#getPinVersion} * @param pinVersion optionally force all dependencies in this group to have this version. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder pinVersion(java.lang.String pinVersion) { this.pinVersion = pinVersion; return this; } /** * Builds the configured instance. * @return a new instance of {@link VersionGroup} * @throws NullPointerException if any required attribute was not provided */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public VersionGroup build() { return new Jsii$Proxy(this); } } /** * An implementation for {@link VersionGroup} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @software.amazon.jsii.Internal final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements VersionGroup { private final java.util.List dependencies; private final java.util.List packages; private final java.util.List dependencyTypes; private final java.lang.Boolean isBanned; private final java.lang.String pinVersion; /** * 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.dependencies = software.amazon.jsii.Kernel.get(this, "dependencies", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.packages = software.amazon.jsii.Kernel.get(this, "packages", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.dependencyTypes = software.amazon.jsii.Kernel.get(this, "dependencyTypes", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.isBanned = software.amazon.jsii.Kernel.get(this, "isBanned", software.amazon.jsii.NativeType.forClass(java.lang.Boolean.class)); this.pinVersion = software.amazon.jsii.Kernel.get(this, "pinVersion", 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.dependencies = java.util.Objects.requireNonNull(builder.dependencies, "dependencies is required"); this.packages = java.util.Objects.requireNonNull(builder.packages, "packages is required"); this.dependencyTypes = builder.dependencyTypes; this.isBanned = builder.isBanned; this.pinVersion = builder.pinVersion; } @Override public final java.util.List getDependencies() { return this.dependencies; } @Override public final java.util.List getPackages() { return this.packages; } @Override public final java.util.List getDependencyTypes() { return this.dependencyTypes; } @Override public final java.lang.Boolean getIsBanned() { return this.isBanned; } @Override public final java.lang.String getPinVersion() { return this.pinVersion; } @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("dependencies", om.valueToTree(this.getDependencies())); data.set("packages", om.valueToTree(this.getPackages())); if (this.getDependencyTypes() != null) { data.set("dependencyTypes", om.valueToTree(this.getDependencyTypes())); } if (this.getIsBanned() != null) { data.set("isBanned", om.valueToTree(this.getIsBanned())); } if (this.getPinVersion() != null) { data.set("pinVersion", om.valueToTree(this.getPinVersion())); } final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); struct.set("fqn", om.valueToTree("@aws-prototyping-sdk/nx-monorepo.VersionGroup")); 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; VersionGroup.Jsii$Proxy that = (VersionGroup.Jsii$Proxy) o; if (!dependencies.equals(that.dependencies)) return false; if (!packages.equals(that.packages)) return false; if (this.dependencyTypes != null ? !this.dependencyTypes.equals(that.dependencyTypes) : that.dependencyTypes != null) return false; if (this.isBanned != null ? !this.isBanned.equals(that.isBanned) : that.isBanned != null) return false; return this.pinVersion != null ? this.pinVersion.equals(that.pinVersion) : that.pinVersion == null; } @Override public final int hashCode() { int result = this.dependencies.hashCode(); result = 31 * result + (this.packages.hashCode()); result = 31 * result + (this.dependencyTypes != null ? this.dependencyTypes.hashCode() : 0); result = 31 * result + (this.isBanned != null ? this.isBanned.hashCode() : 0); result = 31 * result + (this.pinVersion != null ? this.pinVersion.hashCode() : 0); return result; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy