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

tech.condense.cdkconstructs.IDatabase Maven / Gradle / Ivy

There is a newer version: 0.5.2
Show newest version
package tech.condense.cdkconstructs;

/**
 * (experimental) The IDatabase interface allows to write stacks and constructs that depend on a database without being tied to the specific database implementation.
 * 

* Example: *

*

 * // In this example, MyConstruct is used across several IDatabase implementations without being tied to a specific construct or stack
 * interface MyProps {
 *   database: IDatabase;
 * }
 * class MyConstruct extends Construct {
 *   constructor(scope: Construct, id: string, props: MyProps) {
 *    super(scope, id);
 *    new CfnOutput(this, 'DatabaseEndpoint', { value: props.database.endpoint.hostname });
 *   }
 * }
 * interface MyStackProps {
 *   database3: IDatabase;
 * }
 * class MyStack extends cdk.Stack {
 *   constructor(scope: Construct, id: string, props: MyStackProps) {
 *     super(scope, id, props);
 *     new MyConstruct(this, 'MyConstruct1', {
 *       database: new AuroraCluster(this, 'Database', { ... })
 *     });
 *     new MyConstruct(this, 'MyConstruct2', {
 *       database: new DatabaseInstance(this, 'Database', { ... })
 *     });
 *     new MyConstruct(this, 'MyConstruct3', {
 *        database: props.database3
 *     });
 *   }
 * }
 * const database3 = new AuroraClustrStack(app, 'AuroraClusterStack', { ... });
 * new MyStack(app, 'MyStack', { database3 });
 * 
*/ @javax.annotation.Generated(value = "jsii-pacmak/1.103.1 (build bef2dea)", date = "2024-09-03T13:54:47.689Z") @software.amazon.jsii.Jsii(module = tech.condense.cdkconstructs.$Module.class, fqn = "@condensetech/cdk-constructs.IDatabase") @software.amazon.jsii.Jsii.Proxy(IDatabase.Jsii$Proxy.class) @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public interface IDatabase extends software.amazon.jsii.JsiiSerializable, software.amazon.awscdk.services.ec2.IConnectable { /** * (experimental) The endpoint of the database. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.rds.Endpoint getEndpoint(); /** * (experimental) Utility method that returns the secret with the credentials to access the database in a cross-stack compatible way. *

* @param scope This parameter is required. * @param id */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.secretsmanager.ISecret fetchSecret(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope, final @org.jetbrains.annotations.Nullable java.lang.String id); /** * (experimental) Utility method that returns the secret with the credentials to access the database in a cross-stack compatible way. *

* @param scope This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.secretsmanager.ISecret fetchSecret(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope); /** * A proxy class which represents a concrete javascript instance of this type. */ @software.amazon.jsii.Internal final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements tech.condense.cdkconstructs.IDatabase.Jsii$Default { protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); } /** * The network connections associated with this resource. */ @Override @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public final @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.ec2.Connections getConnections() { return software.amazon.jsii.Kernel.get(this, "connections", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.ec2.Connections.class)); } /** * (experimental) The endpoint of the database. */ @Override @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public final @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.rds.Endpoint getEndpoint() { return software.amazon.jsii.Kernel.get(this, "endpoint", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.rds.Endpoint.class)); } /** * (experimental) Utility method that returns the secret with the credentials to access the database in a cross-stack compatible way. *

* @param scope This parameter is required. * @param id */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @Override public final @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.secretsmanager.ISecret fetchSecret(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope, final @org.jetbrains.annotations.Nullable java.lang.String id) { return software.amazon.jsii.Kernel.call(this, "fetchSecret", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.secretsmanager.ISecret.class), new Object[] { java.util.Objects.requireNonNull(scope, "scope is required"), id }); } /** * (experimental) Utility method that returns the secret with the credentials to access the database in a cross-stack compatible way. *

* @param scope This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @Override public final @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.secretsmanager.ISecret fetchSecret(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope) { return software.amazon.jsii.Kernel.call(this, "fetchSecret", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.secretsmanager.ISecret.class), new Object[] { java.util.Objects.requireNonNull(scope, "scope is required") }); } } /** * Internal default implementation for {@link IDatabase}. */ @software.amazon.jsii.Internal interface Jsii$Default extends IDatabase, software.amazon.awscdk.services.ec2.IConnectable.Jsii$Default { /** * The network connections associated with this resource. */ @Override @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) default @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.ec2.Connections getConnections() { return software.amazon.jsii.Kernel.get(this, "connections", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.ec2.Connections.class)); } /** * (experimental) The endpoint of the database. */ @Override @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) default @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.rds.Endpoint getEndpoint() { return software.amazon.jsii.Kernel.get(this, "endpoint", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.rds.Endpoint.class)); } /** * (experimental) Utility method that returns the secret with the credentials to access the database in a cross-stack compatible way. *

* @param scope This parameter is required. * @param id */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @Override default @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.secretsmanager.ISecret fetchSecret(final @org.jetbrains.annotations.NotNull software.constructs.Construct scope, final @org.jetbrains.annotations.Nullable java.lang.String id) { return software.amazon.jsii.Kernel.call(this, "fetchSecret", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.secretsmanager.ISecret.class), new Object[] { java.util.Objects.requireNonNull(scope, "scope is required"), id }); } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy