Class SnsDestinationBuilder

java.lang.Object
com.commercetools.api.models.subscription.SnsDestinationBuilder
All Implemented Interfaces:
Builder<SnsDestination>

public class SnsDestinationBuilder extends Object implements Builder<SnsDestination>
SnsDestinationBuilder
Example to create an instance using the builder pattern

     SnsDestination snsDestination = SnsDestination.builder()
             .topicArn("{topicArn}")
             .build()
 
  • Constructor Details

    • SnsDestinationBuilder

      public SnsDestinationBuilder()
  • Method Details

    • accessKey

      public SnsDestinationBuilder accessKey(@Nullable String accessKey)

      Only present if authenticationMode is set to Credentials.

      Parameters:
      accessKey - value to be set
      Returns:
      Builder
    • accessSecret

      public SnsDestinationBuilder accessSecret(@Nullable String accessSecret)

      Only present if authenticationMode is set to Credentials.

      Parameters:
      accessSecret - value to be set
      Returns:
      Builder
    • topicArn

      public SnsDestinationBuilder topicArn(String topicArn)

      Amazon Resource Name (ARN) of the topic.

      Parameters:
      topicArn - value to be set
      Returns:
      Builder
    • authenticationMode

      public SnsDestinationBuilder authenticationMode(@Nullable AwsAuthenticationMode authenticationMode)

      Defines the method of authentication for the SNS topic.

      Parameters:
      authenticationMode - value to be set
      Returns:
      Builder
    • getAccessKey

      @Nullable public String getAccessKey()

      Only present if authenticationMode is set to Credentials.

      Returns:
      accessKey
    • getAccessSecret

      @Nullable public String getAccessSecret()

      Only present if authenticationMode is set to Credentials.

      Returns:
      accessSecret
    • getTopicArn

      public String getTopicArn()

      Amazon Resource Name (ARN) of the topic.

      Returns:
      topicArn
    • getAuthenticationMode

      @Nullable public AwsAuthenticationMode getAuthenticationMode()

      Defines the method of authentication for the SNS topic.

      Returns:
      authenticationMode
    • build

      public SnsDestination build()
      builds SnsDestination with checking for non-null required values
      Specified by:
      build in interface Builder<SnsDestination>
      Returns:
      SnsDestination
    • buildUnchecked

      public SnsDestination buildUnchecked()
      builds SnsDestination without checking for non-null required values
      Returns:
      SnsDestination
    • of

      public static SnsDestinationBuilder of()
      factory method for an instance of SnsDestinationBuilder
      Returns:
      builder
    • of

      public static SnsDestinationBuilder of(SnsDestination template)
      create builder for SnsDestination instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder