@Generated(value="jsii-pacmak/1.73.0 (build 6faeda3)", date="2023-01-25T18:29:10.175Z") public class S3EventSource extends software.amazon.jsii.JsiiObject implements IEventSource
Example:
import software.amazon.awscdk.services.lambda.eventsources.*; import software.amazon.awscdk.services.s3.*; Function fn; Bucket bucket = new Bucket(this, "Bucket"); fn.addEventSource(S3EventSource.Builder.create(bucket) .events(List.of(EventType.OBJECT_CREATED, EventType.OBJECT_REMOVED)) .filters(List.of(NotificationKeyFilter.builder().prefix("subdir/").build())) .build());
Modifier and Type | Class and Description |
---|---|
static class |
S3EventSource.Builder
A fluent builder for
S3EventSource . |
IEventSource.Jsii$Default, IEventSource.Jsii$Proxy
Modifier | Constructor and Description |
---|---|
|
S3EventSource(Bucket bucket,
S3EventSourceProps props) |
protected |
S3EventSource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
S3EventSource(software.amazon.jsii.JsiiObjectRef objRef) |
Modifier and Type | Method and Description |
---|---|
void |
bind(IFunction target)
Called by `lambda.addEventSource` to allow the event source to bind to this function.
|
Bucket |
getBucket() |
protected S3EventSource(software.amazon.jsii.JsiiObjectRef objRef)
protected S3EventSource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public S3EventSource(Bucket bucket, S3EventSourceProps props)
bucket
- This parameter is required.props
- This parameter is required.public void bind(IFunction target)
bind
in interface IEventSource
target
- This parameter is required.public Bucket getBucket()