Interface CronOptionsWithTimezone
- All Superinterfaces:
CronOptions,software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CronOptionsWithTimezone.Jsii$Proxy
@Generated(value="jsii-pacmak/1.116.0 (build 0eddcff)",
date="2025-10-24T13:34:46.887Z")
@Stability(Stable)
public interface CronOptionsWithTimezone
extends software.amazon.jsii.JsiiSerializable, CronOptions
Options to configure a cron expression.
All fields are strings so you can use complex expressions. Absence of a field implies '*' or '?', whichever one is appropriate.
Example:
LambdaInvoke target;
Schedule rateBasedSchedule = Schedule.Builder.create(this, "Schedule")
.schedule(ScheduleExpression.rate(Duration.minutes(10)))
.target(target)
.description("This is a test rate-based schedule")
.build();
Schedule cronBasedSchedule = Schedule.Builder.create(this, "Schedule")
.schedule(ScheduleExpression.cron(CronOptionsWithTimezone.builder()
.minute("0")
.hour("23")
.day("20")
.month("11")
.timeZone(TimeZone.AMERICA_NEW_YORK)
.build()))
.target(target)
.description("This is a test cron-based schedule that will run at 11:00 PM, on day 20 of the month, only in November in New York timezone")
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCronOptionsWithTimezonestatic final classAn implementation forCronOptionsWithTimezone -
Method Summary
Methods inherited from interface software.amazon.awscdk.services.events.CronOptions
getDay, getHour, getMinute, getMonth, getWeekDay, getYearMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getTimeZone
The timezone to run the schedule in.Default: - TimeZone.ETC_UTC
-
builder
- Returns:
- a
CronOptionsWithTimezone.BuilderofCronOptionsWithTimezone
-