|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ofbiz.service.calendar.TemporalExpression
org.ofbiz.service.calendar.TemporalExpressions.Frequency
public static class TemporalExpressions.Frequency
A temporal expression that represents a frequency.
Field Summary | |
---|---|
protected int |
freqCount
|
protected int |
freqType
|
protected java.util.Date |
start
|
Fields inherited from class org.ofbiz.service.calendar.TemporalExpression |
---|
id, sequence, subSequence |
Constructor Summary | |
---|---|
TemporalExpressions.Frequency(java.util.Date start,
int freqType,
int freqCount)
|
Method Summary | |
---|---|
void |
accept(TemporalExpressionVisitor visitor)
Handles a TemporalExpressionVisitor visit. |
boolean |
equals(java.lang.Object obj)
|
java.util.Calendar |
first(java.util.Calendar cal)
Returns a date representing the first occurrence of this expression on or after a specified date. |
int |
getFreqCount()
Returns the frequency count of this expression. |
int |
getFreqType()
Returns the frequency type of this expression. |
java.util.Date |
getStartDate()
Returns the start date of this expression. |
boolean |
includesDate(java.util.Calendar cal)
Returns true if this expression includes the specified date. |
java.util.Calendar |
next(java.util.Calendar cal)
Returns a date representing the next occurrence of this expression after a specified date. |
protected java.util.Calendar |
prepareCal(java.util.Calendar cal)
|
java.lang.String |
toString()
|
Methods inherited from class org.ofbiz.service.calendar.TemporalExpression |
---|
compareTo, containsExpression, getId, getRange, setId, setStartOfDay |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final java.util.Date start
protected final int freqType
protected final int freqCount
Constructor Detail |
---|
public TemporalExpressions.Frequency(java.util.Date start, int freqType, int freqCount)
start
- Starting date, defaults to current system timefreqType
- One of the following integer values: Calendar.SECOND
Calendar.MINUTE Calendar.HOUR Calendar.DAY_OF_MONTH Calendar.MONTH
Calendar.YEAR
freqCount
- A positive integerMethod Detail |
---|
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public boolean includesDate(java.util.Calendar cal)
TemporalExpression
includesDate
in class TemporalExpression
cal
- A date to evaluate
cal
public java.util.Calendar first(java.util.Calendar cal)
TemporalExpression
null
if there
is no matching date.
first
in class TemporalExpression
cal
- A date to evaluate
null
if no matching date is foundpublic java.util.Calendar next(java.util.Calendar cal)
TemporalExpression
null
if there
is no matching date.
next
in class TemporalExpression
cal
- A date to evaluate
null
if no matching date is foundpublic void accept(TemporalExpressionVisitor visitor)
TemporalExpression
TemporalExpressionVisitor
visit.
accept
in class TemporalExpression
public java.util.Date getStartDate()
public int getFreqType()
public int getFreqCount()
protected java.util.Calendar prepareCal(java.util.Calendar cal)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |