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

org.mongodb.awscdk.resources.mongodbatlas.ConnectionStrings Maven / Gradle / Ivy

There is a newer version: 3.9.0
Show newest version
package org.mongodb.awscdk.resources.mongodbatlas;

/**
 * Collection of Uniform Resource Locators that point to the MongoDB database.
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.94.0 (build b380f01)", date = "2024-02-05T16:04:31.917Z")
@software.amazon.jsii.Jsii(module = org.mongodb.awscdk.resources.mongodbatlas.$Module.class, fqn = "awscdk-resources-mongodbatlas.ConnectionStrings")
@software.amazon.jsii.Jsii.Proxy(ConnectionStrings.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
public interface ConnectionStrings extends software.amazon.jsii.JsiiSerializable {

    /**
     * Network peering connection strings for each interface Virtual Private Cloud (VPC) endpoint that you configured to connect to this cluster.
     * 

* This connection string uses the mongodb+srv:// protocol. The resource returns this parameter once someone creates a network peering connection to this cluster. This protocol tells the application to look up the host seed list in the Domain Name System (DNS). This list synchronizes with the nodes in a cluster. If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to append the seed list or change the URI if the nodes change. Use this URI format if your driver supports it. If it doesn't, use connectionStrings.private. For Amazon Web Services (AWS) clusters, this resource returns this parameter only if you enable custom DNS. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.String getPrivateValue() { return null; } /** * Private endpoint-aware connection strings that use AWS-hosted clusters with Amazon Web Services (AWS) PrivateLink. *

* Each key identifies an Amazon Web Services (AWS) interface endpoint. Each value identifies the related mongodb:// connection string that you use to connect to MongoDB Cloud through the interface endpoint that the key names. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.util.List getPrivateEndpoints() { return null; } /** * Private endpoint-aware connection strings that use AWS-hosted clusters with Amazon Web Services (AWS) PrivateLink. *

* Each key identifies an Amazon Web Services (AWS) interface endpoint. Each value identifies the related mongodb:// connection string that you use to connect to Atlas through the interface endpoint that the key names. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.util.List getPrivateEndpointsSrv() { return null; } /** * Network peering connection strings for each interface Virtual Private Cloud (VPC) endpoint that you configured to connect to this cluster. *

* This connection string uses the mongodb+srv:// protocol. The resource returns this parameter when someone creates a network peering connection to this cluster. This protocol tells the application to look up the host seed list in the Domain Name System (DNS). This list synchronizes with the nodes in a cluster. If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to append the seed list or change the Uniform Resource Identifier (URI) if the nodes change. Use this Uniform Resource Identifier (URI) format if your driver supports it. If it doesn't, use connectionStrings.private. For Amazon Web Services (AWS) clusters, this parameter returns only if you enable custom DNS. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.String getPrivateSrv() { return null; } /** * Private endpoint-aware connection string optimized for sharded clusters that uses the mongodb+srv:// protocol to connect to MongoDB Cloud through a private endpoint. *

* If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to change the Uniform Resource Identifier (URI) if the nodes change. Use this Uniform Resource Identifier (URI) format if your application and Atlas cluster supports it. If it doesn't, use and consult the documentation for connectionStrings.privateEndpoint[n].srvConnectionString. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.util.List getSrvShardOptimizedConnectionString() { return null; } /** * Public connection string that you can use to connect to this cluster. *

* This connection string uses the mongodb:// protocol. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.String getStandard() { return null; } /** * Public connection string that you can use to connect to this cluster. *

* This connection string uses the mongodb+srv:// protocol. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.Nullable java.lang.String getStandardSrv() { return null; } /** * @return a {@link Builder} of {@link ConnectionStrings} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) static Builder builder() { return new Builder(); } /** * A builder for {@link ConnectionStrings} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static final class Builder implements software.amazon.jsii.Builder { java.lang.String privateValue; java.util.List privateEndpoints; java.util.List privateEndpointsSrv; java.lang.String privateSrv; java.util.List srvShardOptimizedConnectionString; java.lang.String standard; java.lang.String standardSrv; /** * Sets the value of {@link ConnectionStrings#getPrivateValue} * @param privateValue Network peering connection strings for each interface Virtual Private Cloud (VPC) endpoint that you configured to connect to this cluster. * This connection string uses the mongodb+srv:// protocol. The resource returns this parameter once someone creates a network peering connection to this cluster. This protocol tells the application to look up the host seed list in the Domain Name System (DNS). This list synchronizes with the nodes in a cluster. If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to append the seed list or change the URI if the nodes change. Use this URI format if your driver supports it. If it doesn't, use connectionStrings.private. For Amazon Web Services (AWS) clusters, this resource returns this parameter only if you enable custom DNS. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder privateValue(java.lang.String privateValue) { this.privateValue = privateValue; return this; } /** * Sets the value of {@link ConnectionStrings#getPrivateEndpoints} * @param privateEndpoints Private endpoint-aware connection strings that use AWS-hosted clusters with Amazon Web Services (AWS) PrivateLink. * Each key identifies an Amazon Web Services (AWS) interface endpoint. Each value identifies the related mongodb:// connection string that you use to connect to MongoDB Cloud through the interface endpoint that the key names. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder privateEndpoints(java.util.List privateEndpoints) { this.privateEndpoints = privateEndpoints; return this; } /** * Sets the value of {@link ConnectionStrings#getPrivateEndpointsSrv} * @param privateEndpointsSrv Private endpoint-aware connection strings that use AWS-hosted clusters with Amazon Web Services (AWS) PrivateLink. * Each key identifies an Amazon Web Services (AWS) interface endpoint. Each value identifies the related mongodb:// connection string that you use to connect to Atlas through the interface endpoint that the key names. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder privateEndpointsSrv(java.util.List privateEndpointsSrv) { this.privateEndpointsSrv = privateEndpointsSrv; return this; } /** * Sets the value of {@link ConnectionStrings#getPrivateSrv} * @param privateSrv Network peering connection strings for each interface Virtual Private Cloud (VPC) endpoint that you configured to connect to this cluster. * This connection string uses the mongodb+srv:// protocol. The resource returns this parameter when someone creates a network peering connection to this cluster. This protocol tells the application to look up the host seed list in the Domain Name System (DNS). This list synchronizes with the nodes in a cluster. If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to append the seed list or change the Uniform Resource Identifier (URI) if the nodes change. Use this Uniform Resource Identifier (URI) format if your driver supports it. If it doesn't, use connectionStrings.private. For Amazon Web Services (AWS) clusters, this parameter returns only if you enable custom DNS. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder privateSrv(java.lang.String privateSrv) { this.privateSrv = privateSrv; return this; } /** * Sets the value of {@link ConnectionStrings#getSrvShardOptimizedConnectionString} * @param srvShardOptimizedConnectionString Private endpoint-aware connection string optimized for sharded clusters that uses the mongodb+srv:// protocol to connect to MongoDB Cloud through a private endpoint. * If the connection string uses this Uniform Resource Identifier (URI) format, you don't need to change the Uniform Resource Identifier (URI) if the nodes change. Use this Uniform Resource Identifier (URI) format if your application and Atlas cluster supports it. If it doesn't, use and consult the documentation for connectionStrings.privateEndpoint[n].srvConnectionString. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder srvShardOptimizedConnectionString(java.util.List srvShardOptimizedConnectionString) { this.srvShardOptimizedConnectionString = srvShardOptimizedConnectionString; return this; } /** * Sets the value of {@link ConnectionStrings#getStandard} * @param standard Public connection string that you can use to connect to this cluster. * This connection string uses the mongodb:// protocol. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder standard(java.lang.String standard) { this.standard = standard; return this; } /** * Sets the value of {@link ConnectionStrings#getStandardSrv} * @param standardSrv Public connection string that you can use to connect to this cluster. * This connection string uses the mongodb+srv:// protocol. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder standardSrv(java.lang.String standardSrv) { this.standardSrv = standardSrv; return this; } /** * Builds the configured instance. * @return a new instance of {@link ConnectionStrings} * @throws NullPointerException if any required attribute was not provided */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public ConnectionStrings build() { return new Jsii$Proxy(this); } } /** * An implementation for {@link ConnectionStrings} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @software.amazon.jsii.Internal final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements ConnectionStrings { private final java.lang.String privateValue; private final java.util.List privateEndpoints; private final java.util.List privateEndpointsSrv; private final java.lang.String privateSrv; private final java.util.List srvShardOptimizedConnectionString; private final java.lang.String standard; private final java.lang.String standardSrv; /** * 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.privateValue = software.amazon.jsii.Kernel.get(this, "private", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.privateEndpoints = software.amazon.jsii.Kernel.get(this, "privateEndpoints", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.privateEndpointsSrv = software.amazon.jsii.Kernel.get(this, "privateEndpointsSrv", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.privateSrv = software.amazon.jsii.Kernel.get(this, "privateSrv", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.srvShardOptimizedConnectionString = software.amazon.jsii.Kernel.get(this, "srvShardOptimizedConnectionString", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class))); this.standard = software.amazon.jsii.Kernel.get(this, "standard", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.standardSrv = software.amazon.jsii.Kernel.get(this, "standardSrv", 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.privateValue = builder.privateValue; this.privateEndpoints = builder.privateEndpoints; this.privateEndpointsSrv = builder.privateEndpointsSrv; this.privateSrv = builder.privateSrv; this.srvShardOptimizedConnectionString = builder.srvShardOptimizedConnectionString; this.standard = builder.standard; this.standardSrv = builder.standardSrv; } @Override public final java.lang.String getPrivateValue() { return this.privateValue; } @Override public final java.util.List getPrivateEndpoints() { return this.privateEndpoints; } @Override public final java.util.List getPrivateEndpointsSrv() { return this.privateEndpointsSrv; } @Override public final java.lang.String getPrivateSrv() { return this.privateSrv; } @Override public final java.util.List getSrvShardOptimizedConnectionString() { return this.srvShardOptimizedConnectionString; } @Override public final java.lang.String getStandard() { return this.standard; } @Override public final java.lang.String getStandardSrv() { return this.standardSrv; } @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.getPrivateValue() != null) { data.set("private", om.valueToTree(this.getPrivateValue())); } if (this.getPrivateEndpoints() != null) { data.set("privateEndpoints", om.valueToTree(this.getPrivateEndpoints())); } if (this.getPrivateEndpointsSrv() != null) { data.set("privateEndpointsSrv", om.valueToTree(this.getPrivateEndpointsSrv())); } if (this.getPrivateSrv() != null) { data.set("privateSrv", om.valueToTree(this.getPrivateSrv())); } if (this.getSrvShardOptimizedConnectionString() != null) { data.set("srvShardOptimizedConnectionString", om.valueToTree(this.getSrvShardOptimizedConnectionString())); } if (this.getStandard() != null) { data.set("standard", om.valueToTree(this.getStandard())); } if (this.getStandardSrv() != null) { data.set("standardSrv", om.valueToTree(this.getStandardSrv())); } final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); struct.set("fqn", om.valueToTree("awscdk-resources-mongodbatlas.ConnectionStrings")); 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; ConnectionStrings.Jsii$Proxy that = (ConnectionStrings.Jsii$Proxy) o; if (this.privateValue != null ? !this.privateValue.equals(that.privateValue) : that.privateValue != null) return false; if (this.privateEndpoints != null ? !this.privateEndpoints.equals(that.privateEndpoints) : that.privateEndpoints != null) return false; if (this.privateEndpointsSrv != null ? !this.privateEndpointsSrv.equals(that.privateEndpointsSrv) : that.privateEndpointsSrv != null) return false; if (this.privateSrv != null ? !this.privateSrv.equals(that.privateSrv) : that.privateSrv != null) return false; if (this.srvShardOptimizedConnectionString != null ? !this.srvShardOptimizedConnectionString.equals(that.srvShardOptimizedConnectionString) : that.srvShardOptimizedConnectionString != null) return false; if (this.standard != null ? !this.standard.equals(that.standard) : that.standard != null) return false; return this.standardSrv != null ? this.standardSrv.equals(that.standardSrv) : that.standardSrv == null; } @Override public final int hashCode() { int result = this.privateValue != null ? this.privateValue.hashCode() : 0; result = 31 * result + (this.privateEndpoints != null ? this.privateEndpoints.hashCode() : 0); result = 31 * result + (this.privateEndpointsSrv != null ? this.privateEndpointsSrv.hashCode() : 0); result = 31 * result + (this.privateSrv != null ? this.privateSrv.hashCode() : 0); result = 31 * result + (this.srvShardOptimizedConnectionString != null ? this.srvShardOptimizedConnectionString.hashCode() : 0); result = 31 * result + (this.standard != null ? this.standard.hashCode() : 0); result = 31 * result + (this.standardSrv != null ? this.standardSrv.hashCode() : 0); return result; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy