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

com.hashicorp.cdktf.TerraformHclModuleOptions Maven / Gradle / Ivy

There is a newer version: 0.21.0-pre.141
Show newest version
package com.hashicorp.cdktf;

/**
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.17.1 (build 2bac5fd)", date = "2021-02-18T13:56:39.648Z")
@software.amazon.jsii.Jsii(module = com.hashicorp.cdktf.$Module.class, fqn = "cdktf.TerraformHclModuleOptions")
@software.amazon.jsii.Jsii.Proxy(TerraformHclModuleOptions.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public interface TerraformHclModuleOptions extends software.amazon.jsii.JsiiSerializable, com.hashicorp.cdktf.TerraformModuleOptions {

    /**
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
    default @org.jetbrains.annotations.Nullable java.util.Map getVariables() {
        return null;
    }

    /**
     * @return a {@link Builder} of {@link TerraformHclModuleOptions}
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
    static Builder builder() {
        return new Builder();
    }
    /**
     * A builder for {@link TerraformHclModuleOptions}
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
    public static final class Builder implements software.amazon.jsii.Builder {
        private java.util.Map variables;
        private java.lang.String source;
        private java.util.List dependsOn;
        private java.util.List providers;
        private java.lang.String version;

        /**
         * Sets the value of {@link TerraformHclModuleOptions#getVariables}
         * @param variables the value to be set.
         * @return {@code this}
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        @SuppressWarnings("unchecked")
        public Builder variables(java.util.Map variables) {
            this.variables = (java.util.Map)variables;
            return this;
        }

        /**
         * Sets the value of {@link TerraformHclModuleOptions#getSource}
         * @param source the value to be set. This parameter is required.
         * @return {@code this}
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        public Builder source(java.lang.String source) {
            this.source = source;
            return this;
        }

        /**
         * Sets the value of {@link TerraformHclModuleOptions#getDependsOn}
         * @param dependsOn the value to be set.
         * @return {@code this}
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        @SuppressWarnings("unchecked")
        public Builder dependsOn(java.util.List dependsOn) {
            this.dependsOn = (java.util.List)dependsOn;
            return this;
        }

        /**
         * Sets the value of {@link TerraformHclModuleOptions#getProviders}
         * @param providers the value to be set.
         * @return {@code this}
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        @SuppressWarnings("unchecked")
        public Builder providers(java.util.List providers) {
            this.providers = (java.util.List)providers;
            return this;
        }

        /**
         * Sets the value of {@link TerraformHclModuleOptions#getVersion}
         * @param version the value to be set.
         * @return {@code this}
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        public Builder version(java.lang.String version) {
            this.version = version;
            return this;
        }

        /**
         * Builds the configured instance.
         * @return a new instance of {@link TerraformHclModuleOptions}
         * @throws NullPointerException if any required attribute was not provided
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
        @Override
        public TerraformHclModuleOptions build() {
            return new Jsii$Proxy(variables, source, dependsOn, providers, version);
        }
    }

    /**
     * An implementation for {@link TerraformHclModuleOptions}
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
    @software.amazon.jsii.Internal
    final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements TerraformHclModuleOptions {
        private final java.util.Map variables;
        private final java.lang.String source;
        private final java.util.List dependsOn;
        private final java.util.List providers;
        private final java.lang.String version;

        /**
         * 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.variables = software.amazon.jsii.Kernel.get(this, "variables", software.amazon.jsii.NativeType.mapOf(software.amazon.jsii.NativeType.forClass(java.lang.Object.class)));
            this.source = software.amazon.jsii.Kernel.get(this, "source", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
            this.dependsOn = software.amazon.jsii.Kernel.get(this, "dependsOn", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(com.hashicorp.cdktf.ITerraformDependable.class)));
            this.providers = software.amazon.jsii.Kernel.get(this, "providers", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.Object.class)));
            this.version = software.amazon.jsii.Kernel.get(this, "version", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
        }

        /**
         * Constructor that initializes the object based on literal property values passed by the {@link Builder}.
         */
        @SuppressWarnings("unchecked")
        protected Jsii$Proxy(final java.util.Map variables, final java.lang.String source, final java.util.List dependsOn, final java.util.List providers, final java.lang.String version) {
            super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
            this.variables = (java.util.Map)variables;
            this.source = java.util.Objects.requireNonNull(source, "source is required");
            this.dependsOn = (java.util.List)dependsOn;
            this.providers = (java.util.List)providers;
            this.version = version;
        }

        @Override
        public final java.util.Map getVariables() {
            return this.variables;
        }

        @Override
        public final java.lang.String getSource() {
            return this.source;
        }

        @Override
        public final java.util.List getDependsOn() {
            return this.dependsOn;
        }

        @Override
        public final java.util.List getProviders() {
            return this.providers;
        }

        @Override
        public final java.lang.String getVersion() {
            return this.version;
        }

        @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();

            if (this.getVariables() != null) {
                data.set("variables", om.valueToTree(this.getVariables()));
            }
            data.set("source", om.valueToTree(this.getSource()));
            if (this.getDependsOn() != null) {
                data.set("dependsOn", om.valueToTree(this.getDependsOn()));
            }
            if (this.getProviders() != null) {
                data.set("providers", om.valueToTree(this.getProviders()));
            }
            if (this.getVersion() != null) {
                data.set("version", om.valueToTree(this.getVersion()));
            }

            final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
            struct.set("fqn", om.valueToTree("cdktf.TerraformHclModuleOptions"));
            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;

            TerraformHclModuleOptions.Jsii$Proxy that = (TerraformHclModuleOptions.Jsii$Proxy) o;

            if (this.variables != null ? !this.variables.equals(that.variables) : that.variables != null) return false;
            if (!source.equals(that.source)) return false;
            if (this.dependsOn != null ? !this.dependsOn.equals(that.dependsOn) : that.dependsOn != null) return false;
            if (this.providers != null ? !this.providers.equals(that.providers) : that.providers != null) return false;
            return this.version != null ? this.version.equals(that.version) : that.version == null;
        }

        @Override
        public final int hashCode() {
            int result = this.variables != null ? this.variables.hashCode() : 0;
            result = 31 * result + (this.source.hashCode());
            result = 31 * result + (this.dependsOn != null ? this.dependsOn.hashCode() : 0);
            result = 31 * result + (this.providers != null ? this.providers.hashCode() : 0);
            result = 31 * result + (this.version != null ? this.version.hashCode() : 0);
            return result;
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy