java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.autoscaling.hooktargets.TopicHook
All Implemented Interfaces:
ILifecycleHookTarget, software.amazon.jsii.JsiiSerializable

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:46.211Z") @Stability(Stable) public class TopicHook extends software.amazon.jsii.JsiiObject implements ILifecycleHookTarget
Use an SNS topic as a hook target.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.autoscaling.hooktargets.*;
 import software.amazon.awscdk.services.sns.*;
 Topic topic;
 TopicHook topicHook = new TopicHook(topic);
 
  • Nested Class Summary

    Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject

    software.amazon.jsii.JsiiObject.InitializationMode

    Nested classes/interfaces inherited from interface software.amazon.awscdk.services.autoscaling.ILifecycleHookTarget

    ILifecycleHookTarget.Jsii$Default, ILifecycleHookTarget.Jsii$Proxy
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
     
     
    protected
    TopicHook(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
     
    protected
    TopicHook(software.amazon.jsii.JsiiObjectRef objRef)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    bind(software.constructs.Construct _scope, BindHookTargetOptions options)
    If an IRole is found in options, grant it topic publishing permissions.

    Methods inherited from class software.amazon.jsii.JsiiObject

    jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface software.amazon.jsii.JsiiSerializable

    $jsii$toJson
  • Constructor Details

    • TopicHook

      protected TopicHook(software.amazon.jsii.JsiiObjectRef objRef)
    • TopicHook

      protected TopicHook(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • TopicHook

      @Stability(Stable) public TopicHook(@NotNull ITopic topic)
      Parameters:
      topic - This parameter is required.
  • Method Details

    • bind

      @Stability(Stable) @NotNull public LifecycleHookTargetConfig bind(@NotNull software.constructs.Construct _scope, @NotNull BindHookTargetOptions options)
      If an IRole is found in options, grant it topic publishing permissions.

      Otherwise, create a new IRole and grant it topic publishing permissions.

      Specified by:
      bind in interface ILifecycleHookTarget
      Parameters:
      _scope - This parameter is required.
      options - This parameter is required.
      Returns:
      the IRole with topic publishing permissions and the ARN of the topic it has publishing permission to.