com.hashicorp.cdktf.DataTerraformRemoteStateHttpConfig Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cdktf Show documentation
Show all versions of cdktf Show documentation
Cloud Development Kit for Terraform
The newest version!
package com.hashicorp.cdktf;
/**
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.102.0 (build e354887)", date = "2024-11-11T10:07:41.919Z")
@software.amazon.jsii.Jsii(module = com.hashicorp.cdktf.$Module.class, fqn = "cdktf.DataTerraformRemoteStateHttpConfig")
@software.amazon.jsii.Jsii.Proxy(DataTerraformRemoteStateHttpConfig.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public interface DataTerraformRemoteStateHttpConfig extends software.amazon.jsii.JsiiSerializable, com.hashicorp.cdktf.DataTerraformRemoteStateConfig, com.hashicorp.cdktf.HttpBackendConfig {
/**
* @return a {@link Builder} of {@link DataTerraformRemoteStateHttpConfig}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link DataTerraformRemoteStateHttpConfig}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public static final class Builder implements software.amazon.jsii.Builder {
java.util.Map defaults;
java.lang.String workspace;
java.lang.String address;
java.lang.String clientCaCertificatePem;
java.lang.String clientCertificatePem;
java.lang.String clientPrivateKeyPem;
java.lang.String lockAddress;
java.lang.String lockMethod;
java.lang.String password;
java.lang.Number retryMax;
java.lang.Number retryWaitMax;
java.lang.Number retryWaitMin;
java.lang.Boolean skipCertVerification;
java.lang.String unlockAddress;
java.lang.String unlockMethod;
java.lang.String updateMethod;
java.lang.String username;
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getDefaults}
* @param defaults the value to be set.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@SuppressWarnings("unchecked")
public Builder defaults(java.util.Map defaults) {
this.defaults = (java.util.Map)defaults;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getWorkspace}
* @param workspace the value to be set.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder workspace(java.lang.String workspace) {
this.workspace = workspace;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getAddress}
* @param address (Required) The address of the REST endpoint. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder address(java.lang.String address) {
this.address = address;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getClientCaCertificatePem}
* @param clientCaCertificatePem (Optional) A PEM-encoded CA certificate chain used by the client to verify server certificates during TLS authentication.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder clientCaCertificatePem(java.lang.String clientCaCertificatePem) {
this.clientCaCertificatePem = clientCaCertificatePem;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getClientCertificatePem}
* @param clientCertificatePem (Optional) A PEM-encoded certificate used by the server to verify the client during mutual TLS (mTLS) authentication.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder clientCertificatePem(java.lang.String clientCertificatePem) {
this.clientCertificatePem = clientCertificatePem;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getClientPrivateKeyPem}
* @param clientPrivateKeyPem (Optional) A PEM-encoded private key, required if client_certificate_pem is specified.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder clientPrivateKeyPem(java.lang.String clientPrivateKeyPem) {
this.clientPrivateKeyPem = clientPrivateKeyPem;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getLockAddress}
* @param lockAddress (Optional) The address of the lock REST endpoint.
* Defaults to disabled.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder lockAddress(java.lang.String lockAddress) {
this.lockAddress = lockAddress;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getLockMethod}
* @param lockMethod (Optional) The HTTP method to use when locking.
* Defaults to LOCK.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder lockMethod(java.lang.String lockMethod) {
this.lockMethod = lockMethod;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getPassword}
* @param password (Optional) The password for HTTP basic authentication.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder password(java.lang.String password) {
this.password = password;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getRetryMax}
* @param retryMax (Optional) The number of HTTP request retries.
* Defaults to 2.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder retryMax(java.lang.Number retryMax) {
this.retryMax = retryMax;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getRetryWaitMax}
* @param retryWaitMax (Optional) The maximum time in seconds to wait between HTTP request attempts.
* Defaults to 30.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder retryWaitMax(java.lang.Number retryWaitMax) {
this.retryWaitMax = retryWaitMax;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getRetryWaitMin}
* @param retryWaitMin (Optional) The minimum time in seconds to wait between HTTP request attempts.
* Defaults to 1.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder retryWaitMin(java.lang.Number retryWaitMin) {
this.retryWaitMin = retryWaitMin;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getSkipCertVerification}
* @param skipCertVerification (Optional) Whether to skip TLS verification.
* Defaults to false.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder skipCertVerification(java.lang.Boolean skipCertVerification) {
this.skipCertVerification = skipCertVerification;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getUnlockAddress}
* @param unlockAddress (Optional) The address of the unlock REST endpoint.
* Defaults to disabled.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder unlockAddress(java.lang.String unlockAddress) {
this.unlockAddress = unlockAddress;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getUnlockMethod}
* @param unlockMethod (Optional) The HTTP method to use when unlocking.
* Defaults to UNLOCK.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder unlockMethod(java.lang.String unlockMethod) {
this.unlockMethod = unlockMethod;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getUpdateMethod}
* @param updateMethod (Optional) HTTP method to use when updating state.
* Defaults to POST.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder updateMethod(java.lang.String updateMethod) {
this.updateMethod = updateMethod;
return this;
}
/**
* Sets the value of {@link DataTerraformRemoteStateHttpConfig#getUsername}
* @param username (Optional) The username for HTTP basic authentication.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder username(java.lang.String username) {
this.username = username;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link DataTerraformRemoteStateHttpConfig}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@Override
public DataTerraformRemoteStateHttpConfig build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link DataTerraformRemoteStateHttpConfig}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements DataTerraformRemoteStateHttpConfig {
private final java.util.Map defaults;
private final java.lang.String workspace;
private final java.lang.String address;
private final java.lang.String clientCaCertificatePem;
private final java.lang.String clientCertificatePem;
private final java.lang.String clientPrivateKeyPem;
private final java.lang.String lockAddress;
private final java.lang.String lockMethod;
private final java.lang.String password;
private final java.lang.Number retryMax;
private final java.lang.Number retryWaitMax;
private final java.lang.Number retryWaitMin;
private final java.lang.Boolean skipCertVerification;
private final java.lang.String unlockAddress;
private final java.lang.String unlockMethod;
private final java.lang.String updateMethod;
private final java.lang.String username;
/**
* 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.defaults = software.amazon.jsii.Kernel.get(this, "defaults", software.amazon.jsii.NativeType.mapOf(software.amazon.jsii.NativeType.forClass(java.lang.Object.class)));
this.workspace = software.amazon.jsii.Kernel.get(this, "workspace", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.address = software.amazon.jsii.Kernel.get(this, "address", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.clientCaCertificatePem = software.amazon.jsii.Kernel.get(this, "clientCaCertificatePem", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.clientCertificatePem = software.amazon.jsii.Kernel.get(this, "clientCertificatePem", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.clientPrivateKeyPem = software.amazon.jsii.Kernel.get(this, "clientPrivateKeyPem", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.lockAddress = software.amazon.jsii.Kernel.get(this, "lockAddress", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.lockMethod = software.amazon.jsii.Kernel.get(this, "lockMethod", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.password = software.amazon.jsii.Kernel.get(this, "password", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.retryMax = software.amazon.jsii.Kernel.get(this, "retryMax", software.amazon.jsii.NativeType.forClass(java.lang.Number.class));
this.retryWaitMax = software.amazon.jsii.Kernel.get(this, "retryWaitMax", software.amazon.jsii.NativeType.forClass(java.lang.Number.class));
this.retryWaitMin = software.amazon.jsii.Kernel.get(this, "retryWaitMin", software.amazon.jsii.NativeType.forClass(java.lang.Number.class));
this.skipCertVerification = software.amazon.jsii.Kernel.get(this, "skipCertVerification", software.amazon.jsii.NativeType.forClass(java.lang.Boolean.class));
this.unlockAddress = software.amazon.jsii.Kernel.get(this, "unlockAddress", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.unlockMethod = software.amazon.jsii.Kernel.get(this, "unlockMethod", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.updateMethod = software.amazon.jsii.Kernel.get(this, "updateMethod", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.username = software.amazon.jsii.Kernel.get(this, "username", 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 Builder builder) {
super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
this.defaults = (java.util.Map)builder.defaults;
this.workspace = builder.workspace;
this.address = java.util.Objects.requireNonNull(builder.address, "address is required");
this.clientCaCertificatePem = builder.clientCaCertificatePem;
this.clientCertificatePem = builder.clientCertificatePem;
this.clientPrivateKeyPem = builder.clientPrivateKeyPem;
this.lockAddress = builder.lockAddress;
this.lockMethod = builder.lockMethod;
this.password = builder.password;
this.retryMax = builder.retryMax;
this.retryWaitMax = builder.retryWaitMax;
this.retryWaitMin = builder.retryWaitMin;
this.skipCertVerification = builder.skipCertVerification;
this.unlockAddress = builder.unlockAddress;
this.unlockMethod = builder.unlockMethod;
this.updateMethod = builder.updateMethod;
this.username = builder.username;
}
@Override
public final java.util.Map getDefaults() {
return this.defaults;
}
@Override
public final java.lang.String getWorkspace() {
return this.workspace;
}
@Override
public final java.lang.String getAddress() {
return this.address;
}
@Override
public final java.lang.String getClientCaCertificatePem() {
return this.clientCaCertificatePem;
}
@Override
public final java.lang.String getClientCertificatePem() {
return this.clientCertificatePem;
}
@Override
public final java.lang.String getClientPrivateKeyPem() {
return this.clientPrivateKeyPem;
}
@Override
public final java.lang.String getLockAddress() {
return this.lockAddress;
}
@Override
public final java.lang.String getLockMethod() {
return this.lockMethod;
}
@Override
public final java.lang.String getPassword() {
return this.password;
}
@Override
public final java.lang.Number getRetryMax() {
return this.retryMax;
}
@Override
public final java.lang.Number getRetryWaitMax() {
return this.retryWaitMax;
}
@Override
public final java.lang.Number getRetryWaitMin() {
return this.retryWaitMin;
}
@Override
public final java.lang.Boolean getSkipCertVerification() {
return this.skipCertVerification;
}
@Override
public final java.lang.String getUnlockAddress() {
return this.unlockAddress;
}
@Override
public final java.lang.String getUnlockMethod() {
return this.unlockMethod;
}
@Override
public final java.lang.String getUpdateMethod() {
return this.updateMethod;
}
@Override
public final java.lang.String getUsername() {
return this.username;
}
@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.getDefaults() != null) {
data.set("defaults", om.valueToTree(this.getDefaults()));
}
if (this.getWorkspace() != null) {
data.set("workspace", om.valueToTree(this.getWorkspace()));
}
data.set("address", om.valueToTree(this.getAddress()));
if (this.getClientCaCertificatePem() != null) {
data.set("clientCaCertificatePem", om.valueToTree(this.getClientCaCertificatePem()));
}
if (this.getClientCertificatePem() != null) {
data.set("clientCertificatePem", om.valueToTree(this.getClientCertificatePem()));
}
if (this.getClientPrivateKeyPem() != null) {
data.set("clientPrivateKeyPem", om.valueToTree(this.getClientPrivateKeyPem()));
}
if (this.getLockAddress() != null) {
data.set("lockAddress", om.valueToTree(this.getLockAddress()));
}
if (this.getLockMethod() != null) {
data.set("lockMethod", om.valueToTree(this.getLockMethod()));
}
if (this.getPassword() != null) {
data.set("password", om.valueToTree(this.getPassword()));
}
if (this.getRetryMax() != null) {
data.set("retryMax", om.valueToTree(this.getRetryMax()));
}
if (this.getRetryWaitMax() != null) {
data.set("retryWaitMax", om.valueToTree(this.getRetryWaitMax()));
}
if (this.getRetryWaitMin() != null) {
data.set("retryWaitMin", om.valueToTree(this.getRetryWaitMin()));
}
if (this.getSkipCertVerification() != null) {
data.set("skipCertVerification", om.valueToTree(this.getSkipCertVerification()));
}
if (this.getUnlockAddress() != null) {
data.set("unlockAddress", om.valueToTree(this.getUnlockAddress()));
}
if (this.getUnlockMethod() != null) {
data.set("unlockMethod", om.valueToTree(this.getUnlockMethod()));
}
if (this.getUpdateMethod() != null) {
data.set("updateMethod", om.valueToTree(this.getUpdateMethod()));
}
if (this.getUsername() != null) {
data.set("username", om.valueToTree(this.getUsername()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("cdktf.DataTerraformRemoteStateHttpConfig"));
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;
DataTerraformRemoteStateHttpConfig.Jsii$Proxy that = (DataTerraformRemoteStateHttpConfig.Jsii$Proxy) o;
if (this.defaults != null ? !this.defaults.equals(that.defaults) : that.defaults != null) return false;
if (this.workspace != null ? !this.workspace.equals(that.workspace) : that.workspace != null) return false;
if (!address.equals(that.address)) return false;
if (this.clientCaCertificatePem != null ? !this.clientCaCertificatePem.equals(that.clientCaCertificatePem) : that.clientCaCertificatePem != null) return false;
if (this.clientCertificatePem != null ? !this.clientCertificatePem.equals(that.clientCertificatePem) : that.clientCertificatePem != null) return false;
if (this.clientPrivateKeyPem != null ? !this.clientPrivateKeyPem.equals(that.clientPrivateKeyPem) : that.clientPrivateKeyPem != null) return false;
if (this.lockAddress != null ? !this.lockAddress.equals(that.lockAddress) : that.lockAddress != null) return false;
if (this.lockMethod != null ? !this.lockMethod.equals(that.lockMethod) : that.lockMethod != null) return false;
if (this.password != null ? !this.password.equals(that.password) : that.password != null) return false;
if (this.retryMax != null ? !this.retryMax.equals(that.retryMax) : that.retryMax != null) return false;
if (this.retryWaitMax != null ? !this.retryWaitMax.equals(that.retryWaitMax) : that.retryWaitMax != null) return false;
if (this.retryWaitMin != null ? !this.retryWaitMin.equals(that.retryWaitMin) : that.retryWaitMin != null) return false;
if (this.skipCertVerification != null ? !this.skipCertVerification.equals(that.skipCertVerification) : that.skipCertVerification != null) return false;
if (this.unlockAddress != null ? !this.unlockAddress.equals(that.unlockAddress) : that.unlockAddress != null) return false;
if (this.unlockMethod != null ? !this.unlockMethod.equals(that.unlockMethod) : that.unlockMethod != null) return false;
if (this.updateMethod != null ? !this.updateMethod.equals(that.updateMethod) : that.updateMethod != null) return false;
return this.username != null ? this.username.equals(that.username) : that.username == null;
}
@Override
public final int hashCode() {
int result = this.defaults != null ? this.defaults.hashCode() : 0;
result = 31 * result + (this.workspace != null ? this.workspace.hashCode() : 0);
result = 31 * result + (this.address.hashCode());
result = 31 * result + (this.clientCaCertificatePem != null ? this.clientCaCertificatePem.hashCode() : 0);
result = 31 * result + (this.clientCertificatePem != null ? this.clientCertificatePem.hashCode() : 0);
result = 31 * result + (this.clientPrivateKeyPem != null ? this.clientPrivateKeyPem.hashCode() : 0);
result = 31 * result + (this.lockAddress != null ? this.lockAddress.hashCode() : 0);
result = 31 * result + (this.lockMethod != null ? this.lockMethod.hashCode() : 0);
result = 31 * result + (this.password != null ? this.password.hashCode() : 0);
result = 31 * result + (this.retryMax != null ? this.retryMax.hashCode() : 0);
result = 31 * result + (this.retryWaitMax != null ? this.retryWaitMax.hashCode() : 0);
result = 31 * result + (this.retryWaitMin != null ? this.retryWaitMin.hashCode() : 0);
result = 31 * result + (this.skipCertVerification != null ? this.skipCertVerification.hashCode() : 0);
result = 31 * result + (this.unlockAddress != null ? this.unlockAddress.hashCode() : 0);
result = 31 * result + (this.unlockMethod != null ? this.unlockMethod.hashCode() : 0);
result = 31 * result + (this.updateMethod != null ? this.updateMethod.hashCode() : 0);
result = 31 * result + (this.username != null ? this.username.hashCode() : 0);
return result;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy