|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.pentaho.reporting.engine.classic.core.modules.gui.base.date.AnnualDateRule
org.pentaho.reporting.engine.classic.core.modules.gui.base.date.RelativeDayOfWeekRule
public class RelativeDayOfWeekRule
An annual date rule that returns a date for each year based on (a) a reference rule; (b) a day of the week; and (c) a selection parameter (SerialDate.PRECEDING, SerialDate.NEAREST, SerialDate.FOLLOWING).
For example, Good Friday can be specified as 'the Friday PRECEDING Easter Sunday'.
Constructor Summary | |
---|---|
RelativeDayOfWeekRule()
Deprecated. Default constructor - builds a rule for the Monday following 1 January. |
|
RelativeDayOfWeekRule(AnnualDateRule subrule,
int dayOfWeek,
int relative)
Deprecated. Standard constructor - builds rule based on the supplied sub-rule. |
Method Summary | |
---|---|
Object |
clone()
Deprecated. Creates a clone of this rule. |
SerialDate |
getDate(int year)
Deprecated. Returns the date generated by this rule, for the specified year. |
int |
getDayOfWeek()
Deprecated. Returns the day-of-the-week for this rule. |
int |
getRelative()
Deprecated. Returns the 'relative' attribute, that determines *which* day-of-the-week we are interested in (SerialDate.PRECEDING, SerialDate.NEAREST or SerialDate.FOLLOWING). |
AnnualDateRule |
getSubrule()
Deprecated. Returns the sub-rule (also called the reference rule). |
void |
setDayOfWeek(int dayOfWeek)
Deprecated. Sets the day-of-the-week for this rule. |
void |
setRelative(int relative)
Deprecated. Sets the 'relative' attribute (SerialDate.PRECEDING, SerialDate.NEAREST, SerialDate.FOLLOWING). |
void |
setSubrule(AnnualDateRule subrule)
Deprecated. Sets the sub-rule. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RelativeDayOfWeekRule()
public RelativeDayOfWeekRule(AnnualDateRule subrule, int dayOfWeek, int relative)
subrule
- the rule that determines the reference date.dayOfWeek
- the day-of-the-week relative to the reference date.relative
- indicates *which* day-of-the-week (preceding, nearest
or following).Method Detail |
---|
public AnnualDateRule getSubrule()
public void setSubrule(AnnualDateRule subrule)
subrule
- the annual date rule that determines the reference date
for this rule.public int getDayOfWeek()
public void setDayOfWeek(int dayOfWeek)
dayOfWeek
- the day-of-the-week (SerialDate.MONDAY,
SerialDate.TUESDAY, and so on).public int getRelative()
public void setRelative(int relative)
relative
- determines *which* day-of-the-week is selected by this
rule.public Object clone() throws CloneNotSupportedException
clone
in class AnnualDateRule
CloneNotSupportedException
- this should never happen.public SerialDate getDate(int year)
getDate
in class AnnualDateRule
year
- the year (1900 <= year <= 9999).
null
).
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |