public class CronValidator extends Object
CronExpressionValidator
, except that
the error messages go through translation.Constructor and Description |
---|
CronValidator(I18nHelper i18nHelper,
com.atlassian.scheduler.SchedulerService schedulerService) |
Modifier and Type | Method and Description |
---|---|
io.atlassian.fugue.Option<String> |
validateCron(String expr)
Validates a cron expression using JIRA's default time zone
|
io.atlassian.fugue.Option<String> |
validateCron(String expr,
TimeZone timeZone)
Validates a cron expression using the specified time zone.
|
public CronValidator(I18nHelper i18nHelper, com.atlassian.scheduler.SchedulerService schedulerService)
public io.atlassian.fugue.Option<String> validateCron(String expr)
expr
- the Cron Expression to validate and turn into triggerpublic io.atlassian.fugue.Option<String> validateCron(String expr, @Nullable TimeZone timeZone)
expr
- the Cron Expression to validate and turn into triggertimeZone
- the time zone to use when checking that the cron expression will result in a job that runs;
may be null
to indicate that JIRA's default time zone should be usedCopyright © 2002-2023 Atlassian. All Rights Reserved.