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

software.amazon.awscdk.services.sns.subscriptions.EmailSubscription Maven / Gradle / Ivy

There is a newer version: 1.204.0
Show newest version
package software.amazon.awscdk.services.sns.subscriptions;

/**
 * Use an email address as a subscription target.
 * 

* Email subscriptions require confirmation. */ @javax.annotation.Generated(value = "jsii-pacmak/1.15.0 (build 585166b)", date = "2020-12-22T12:13:02.074Z") @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @software.amazon.jsii.Jsii(module = software.amazon.awscdk.services.sns.subscriptions.$Module.class, fqn = "@aws-cdk/aws-sns-subscriptions.EmailSubscription") public class EmailSubscription extends software.amazon.jsii.JsiiObject implements software.amazon.awscdk.services.sns.ITopicSubscription { protected EmailSubscription(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); } protected EmailSubscription(final software.amazon.jsii.JsiiObject.InitializationMode initializationMode) { super(initializationMode); } /** * @param emailAddress This parameter is required. * @param props */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public EmailSubscription(final @org.jetbrains.annotations.NotNull java.lang.String emailAddress, final @org.jetbrains.annotations.Nullable software.amazon.awscdk.services.sns.subscriptions.EmailSubscriptionProps props) { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); software.amazon.jsii.JsiiEngine.getInstance().createNewObject(this, new Object[] { java.util.Objects.requireNonNull(emailAddress, "emailAddress is required"), props }); } /** * @param emailAddress This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public EmailSubscription(final @org.jetbrains.annotations.NotNull java.lang.String emailAddress) { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); software.amazon.jsii.JsiiEngine.getInstance().createNewObject(this, new Object[] { java.util.Objects.requireNonNull(emailAddress, "emailAddress is required") }); } /** * Returns a configuration for an email address to subscribe to an SNS topic. *

* @param _topic This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.sns.TopicSubscriptionConfig bind(final @org.jetbrains.annotations.NotNull software.amazon.awscdk.services.sns.ITopic _topic) { return software.amazon.jsii.Kernel.call(this, "bind", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.sns.TopicSubscriptionConfig.class), new Object[] { java.util.Objects.requireNonNull(_topic, "_topic is required") }); } /** * A fluent builder for {@link software.amazon.awscdk.services.sns.subscriptions.EmailSubscription}. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static final class Builder implements software.amazon.jsii.Builder { /** * @return a new instance of {@link Builder}. * @param emailAddress This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public static Builder create(final java.lang.String emailAddress) { return new Builder(emailAddress); } private final java.lang.String emailAddress; private software.amazon.awscdk.services.sns.subscriptions.EmailSubscriptionProps.Builder props; private Builder(final java.lang.String emailAddress) { this.emailAddress = emailAddress; } /** * Queue to be used as dead letter queue. *

* If not passed no dead letter queue is enabled. *

* Default: - No dead letter queue enabled. *

* @return {@code this} * @param deadLetterQueue Queue to be used as dead letter queue. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder deadLetterQueue(final software.amazon.awscdk.services.sqs.IQueue deadLetterQueue) { this.props().deadLetterQueue(deadLetterQueue); return this; } /** * The filter policy. *

* Default: - all messages are delivered *

* @return {@code this} * @param filterPolicy The filter policy. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder filterPolicy(final java.util.Map filterPolicy) { this.props().filterPolicy(filterPolicy); return this; } /** * Indicates if the full notification JSON should be sent to the email address or just the message text. *

* Default: false (Message text) *

* @return {@code this} * @param json Indicates if the full notification JSON should be sent to the email address or just the message text. This parameter is required. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) public Builder json(final java.lang.Boolean json) { this.props().json(json); return this; } /** * @returns a newly built instance of {@link software.amazon.awscdk.services.sns.subscriptions.EmailSubscription}. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable) @Override public software.amazon.awscdk.services.sns.subscriptions.EmailSubscription build() { return new software.amazon.awscdk.services.sns.subscriptions.EmailSubscription( this.emailAddress, this.props != null ? this.props.build() : null ); } private software.amazon.awscdk.services.sns.subscriptions.EmailSubscriptionProps.Builder props() { if (this.props == null) { this.props = new software.amazon.awscdk.services.sns.subscriptions.EmailSubscriptionProps.Builder(); } return this.props; } } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy