flux
Interface CronForLoop

All Superinterfaces:
Cron, CronSlice, java.io.Serializable, TimeExpression

public interface CronForLoop
extends Cron

A new Cron "for" loop represents a timing loop. The timing loop begins with a start constraint, finishes with an endConstraint, and contains intermittent timing points as specified by an increment constraint. The timing loop finishes when an end constraint is reached or when a loop count is exhausted, whichever comes first.

Note that the get(CronColumn) method throws an IllegalArgumentException if the specified Cron column is inside the boundaries of the Cron slices within this Cron "for" loop.

Author:
Copyright 2014 Flux Corporation. All rights reserved.

Field Summary
static int INFINITY
          Indicates that a timing loop will fire indefinitely.
 
Fields inherited from interface flux.Cron
APR, APRIL, AUG, AUGUST, DEC, DECEMBER, FEB, FEBRUARY, FRI, FRIDAY, JAN, JANUARY, JUL, JULY, JUN, JUNE, MAR, MARCH, MAY_INT, MAY_STRING, MON, MONDAY, NOV, NOVEMBER, OCT, OCTOBER, SAT, SATURDAY, SEP, SEPTEMBER, SUN, SUNDAY, THU, THURSDAY, TUE, TUESDAY, WED, WEDNESDAY
 
Method Summary
 int getCount()
          Returns the maximum number of times the timing loop will fire.
 CronSlice getEndConstraint()
          Returns the constraint when the timing loop finishes.
 CronColumn getForLoopEndingCronColumn()
          Returns the ending Cron column for the Cron slices within this Cron for loop.
 CronColumn getForLoopStartingCronColumn()
          Returns the starting Cron column for the Cron slices within this Cron for loop.
 CronSlice getIncrementConstraint()
          Returns the constraint that specifies intermittent timing points between the start and end constraints.
 CronSlice getStartConstraint()
          Returns the constraint when the timing loop begins.
 
Methods inherited from interface flux.Cron
isCronForLoop, isCronOr, isRegularCron, previous, previous, toString
 
Methods inherited from interface flux.CronSlice
add, add, add, add, add, add, addAll, addAll, get, getEndingCronColumn, getStartingCronColumn, includesAllValues
 
Methods inherited from interface flux.TimeExpression
accept, getBusinessInterval, getTimeZone, next, next, reset, setBusinessInterval, setTimeZone
 

Field Detail

INFINITY

static final int INFINITY
Indicates that a timing loop will fire indefinitely.

See Also:
Constant Field Values
Method Detail

getCount

int getCount()
Returns the maximum number of times the timing loop will fire.

Returns:
The maximum number of times the timing loop will fire. May return the constant INFINITY.
See Also:
INFINITY

getEndConstraint

CronSlice getEndConstraint()
Returns the constraint when the timing loop finishes.

Returns:
The constraint when the timing loop finishes. Returns null if there is no end constraint.

getForLoopEndingCronColumn

CronColumn getForLoopEndingCronColumn()
Returns the ending Cron column for the Cron slices within this Cron for loop. The ending Cron column is to the right of, or the same as, the starting Cron column.

Returns:
The ending Cron column for this Cron "for" loop.

getForLoopStartingCronColumn

CronColumn getForLoopStartingCronColumn()
Returns the starting Cron column for the Cron slices within this Cron for loop. The starting Cron column is to the left of, or the same as, the ending Cron column.

Returns:
The starting Cron column for this Cron "for" loop.

getIncrementConstraint

CronSlice getIncrementConstraint()
Returns the constraint that specifies intermittent timing points between the start and end constraints.

Returns:
The constraint that specifies intermittent timing points between the start and end constraints.

getStartConstraint

CronSlice getStartConstraint()
Returns the constraint when the timing loop begins.

Returns:
The constraint when the timing loop begins.


© 2014 Flux Corporation. All rights reserved.