Skip to content

Commit

Permalink
Issue #35 code review comment to make interface methods explicitly pu…
Browse files Browse the repository at this point in the history
…blic for clarity
  • Loading branch information
njr-11 committed Oct 4, 2021
1 parent 8168ccc commit 25ea349
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public interface ZonedTrigger extends Trigger {
* method was invoked to schedule the task.
* @return the date/time after which the next execution of the task should start.
*/
ZonedDateTime getNextRunTime(LastExecution lastExecutionInfo, ZonedDateTime taskScheduledTime);
public ZonedDateTime getNextRunTime(LastExecution lastExecutionInfo, ZonedDateTime taskScheduledTime);

/**
* Retrieve the next time that the task should run after.
Expand All @@ -99,7 +99,7 @@ public interface ZonedTrigger extends Trigger {
* @return the date/time after which the next execution of the task should start.
* @throws IllegalArgumentException if the next run time is too large to represent as a <code>Date</code>.
*/
default Date getNextRunTime(LastExecution lastExecutionInfo, Date taskScheduledTime) {
public default Date getNextRunTime(LastExecution lastExecutionInfo, Date taskScheduledTime) {
ZonedDateTime nextTime = getNextRunTime(lastExecutionInfo, taskScheduledTime.toInstant().atZone(getZoneId()));
return Date.from(nextTime.toInstant());
}
Expand All @@ -117,7 +117,7 @@ default Date getNextRunTime(LastExecution lastExecutionInfo, Date taskScheduledT
*
* @return timezone to use for operations on this trigger.
*/
default ZoneId getZoneId() {
public default ZoneId getZoneId() {
return ZoneId.systemDefault();
}

Expand All @@ -140,7 +140,7 @@ default ZoneId getZoneId() {
* is scheduled to start.
* @return true if the task should be skipped and rescheduled.
*/
default boolean skipRun(LastExecution lastExecutionInfo, ZonedDateTime scheduledRunTime) {
public default boolean skipRun(LastExecution lastExecutionInfo, ZonedDateTime scheduledRunTime) {
return false;
}

Expand All @@ -157,7 +157,7 @@ default boolean skipRun(LastExecution lastExecutionInfo, ZonedDateTime scheduled
* is scheduled to start.
* @return true if the task should be skipped and rescheduled.
*/
default boolean skipRun(LastExecution lastExecutionInfo, Date scheduledRunTime) {
public default boolean skipRun(LastExecution lastExecutionInfo, Date scheduledRunTime) {
return skipRun(lastExecutionInfo, scheduledRunTime.toInstant().atZone(getZoneId()));
}
}

0 comments on commit 25ea349

Please sign in to comment.