Class SnsEventSource
Use an Amazon SNS topic as an event source for AWS Lambda.
Inheritance
System.Object
SnsEventSource
Implements
Namespace: Amazon.CDK.AWS.Lambda.EventSources
Assembly: Amazon.CDK.AWS.Lambda.EventSources.dll
Syntax (csharp)
public class SnsEventSource : DeputyBase, IEventSource
Syntax (vb)
Public Class SnsEventSource
Inherits DeputyBase
Implements IEventSource
Remarks
ExampleMetadata: infused
Examples
using Amazon.CDK.AWS.SNS;
using Amazon.CDK.AWS.Lambda.EventSources;
Topic topic;
Function fn;
var deadLetterQueue = new Queue(this, "deadLetterQueue");
fn.AddEventSource(new SnsEventSource(topic, new SnsEventSourceProps {
FilterPolicy = new Dictionary<string, object> { },
DeadLetterQueue = deadLetterQueue
}));
Synopsis
Constructors
SnsEventSource(ITopic, ISnsEventSourceProps) | |
SnsEventSource(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
SnsEventSource(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
Topic |
Methods
Bind(IFunction) | Called by |
Constructors
SnsEventSource(ITopic, ISnsEventSourceProps)
public SnsEventSource(ITopic topic, ISnsEventSourceProps props = null)
Parameters
- topic ITopic
- props ISnsEventSourceProps
SnsEventSource(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected SnsEventSource(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
SnsEventSource(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected SnsEventSource(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
Topic
Methods
Bind(IFunction)
Called by lambda.addEventSource
to allow the event source to bind to this function.
public virtual void Bind(IFunction target)
Parameters
- target IFunction