public class MonthlyCalendarKeyword extends CalendarKeyword
| Constructor and Description |
|---|
MonthlyCalendarKeyword(UC4ObjectName name)
Constructs a new
MonthlyCalendarKeyword. |
MonthlyCalendarKeyword(UC4ObjectName name,
int nMonth,
int startMonth,
int endMonth)
Constructs a new
MonthlyCalendarKeyword. |
| Modifier and Type | Method and Description |
|---|---|
void |
addDate(Integer day)
Adds a day to the selected days.
|
int |
getEndMonth()
Returns the number of the end month of the monthly interval.
|
Integer |
getIntervalEndDay()
Returns the end day of the interval.
|
int |
getIntervalEveryDay()
Returns the interval in days.
|
Integer |
getIntervalStartDay()
Returns the start day of the interval.
|
int |
getNMonth()
Returns the period in month.
|
int |
getStartMonth()
Returns the number of the start month of the monthly interval.
|
boolean |
hasDefinedInterval()
Returns
true if this yearly keyword has a defined interval. |
void |
inDefinedInterval(int everyNday,
boolean beginOfMonth,
Integer start,
Integer end)
Defines an interval for this monthly keyword.
|
boolean |
isGroup()
Returns
true if this is a group keyword. |
boolean |
isIntervalBeginOfMonth()
Returns the direction for counting the days.
|
boolean |
isMonthly()
Returns
true if this is a monthly keyword. |
boolean |
isOnDefinedCalendarDays()
Returns
true if the definition of calendar days is selected. |
boolean |
isRoll()
Returns
true if this is a roll keyword. |
boolean |
isStatic()
Returns
true if this is a static keyword. |
boolean |
isWeekly()
Returns
true if this is a weekly keyword. |
boolean |
isYearly()
Returns
true if this is a yearly keyword. |
boolean |
removeDate(Integer day)
Removes the specified day from the selected days.
|
Iterator<Integer> |
selectedDates()
Returns an iterator over
Integer. |
void |
selectOnDefinedCalendarDays(boolean beginOfMonth)
If this method is called the selected calendar days are used.
|
void |
setEndMonth(int endMonth)
Sets the number of the end month of the monthly interval.
|
void |
setNMonth(int month)
Sets the period in month.
|
void |
setStartMonth(int startMonth)
Sets the number of the start month of the monthly interval.
|
containsDate, equals, getCalendarName, getErrorMessageInsert, getErrorMessageNumber, getErrorText, getName, getPreCalculatedDates, hashCode, setErrorMessageInsert, setName, toStringpublic MonthlyCalendarKeyword(UC4ObjectName name, int nMonth, int startMonth, int endMonth)
MonthlyCalendarKeyword.name - Name of the calendar keywordnMonth - Every n month, integer between 1 and 12startMonth - Start from month, integer beetween 1 and 12endMonth - End with month, integer beetween 1 and 12public MonthlyCalendarKeyword(UC4ObjectName name)
MonthlyCalendarKeyword.
Every 1 Month starting with month 1 and ending with 12 is selected.name - Name of the calendar keywordpublic void selectOnDefinedCalendarDays(boolean beginOfMonth)
inDefinedInterval).beginOfMonth - Direction to count the days, if false days are counted from the end of the monthpublic boolean isOnDefinedCalendarDays()
true if the definition of calendar days is selected.public Iterator<Integer> selectedDates()
Integer.
The integer contains the number of the day.
This iterator can be used to read the selected days and remove days using the remove method
of the Iterator.public void addDate(Integer day)
day - Daypublic boolean removeDate(Integer day)
day - Daypublic int getEndMonth()
public void setEndMonth(int endMonth)
endMonth - End month, integer between 1 and 12public void inDefinedInterval(int everyNday,
boolean beginOfMonth,
Integer start,
Integer end)
everyNday - Every n day, integer between 1 and 365beginOfMonth - Direction for day counting, true means that every n day from the beginning of the year is countedstart - Start dayend - End daypublic boolean isIntervalBeginOfMonth()
public Integer getIntervalEndDay()
public int getIntervalEveryDay()
public Integer getIntervalStartDay()
public int getNMonth()
public void setNMonth(int month)
month - Integer containing the periodpublic int getStartMonth()
public void setStartMonth(int startMonth)
startMonth - Start month, integer between 1 and 12public boolean hasDefinedInterval()
true if this yearly keyword has a defined interval.
If this method returns false single dates are selected for this yearly keyword.public boolean isStatic()
CalendarKeywordtrue if this is a static keyword.isStatic in class CalendarKeywordpublic boolean isWeekly()
CalendarKeywordtrue if this is a weekly keyword.isWeekly in class CalendarKeywordpublic boolean isMonthly()
CalendarKeywordtrue if this is a monthly keyword.isMonthly in class CalendarKeywordpublic boolean isYearly()
CalendarKeywordtrue if this is a yearly keyword.isYearly in class CalendarKeywordpublic boolean isGroup()
CalendarKeywordtrue if this is a group keyword.isGroup in class CalendarKeywordpublic boolean isRoll()
CalendarKeywordtrue if this is a roll keyword.isRoll in class CalendarKeywordCopyright © 2021. All rights reserved.