Package com.uc4.api.objects
Class RollCalendarKeyword
- java.lang.Object
 - 
- com.uc4.api.objects.CalendarKeyword
 - 
- com.uc4.api.objects.RollCalendarKeyword
 
 
 
- 
public class RollCalendarKeyword extends CalendarKeyword
This class represents a Roll Calendar Keyword. 
- 
- 
Constructor Summary
Constructors Modifier Constructor Description RollCalendarKeyword(UC4ObjectName name, CalendarCondition cond)Constructs a newRollCalendarKeywordusing the specified source calendar condition.protectedRollCalendarKeyword(org.w3c.dom.Element keyword, java.lang.String string) 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddCollision(RollCalendarCollision coll)Adds aRollCalendarCollisionto the list of reactions in case of collision.intcollionsSize()Returns the number of entries in the collision list.java.util.Iterator<RollCalendarCollision>collisionIterator()Returns an iterator overRollCalendarCollision.intgetAdjustDays()Returns the number of days of adjustment.CalendarConditiongetAdjustmentCalendar()Returns the name and keyword of the calendar which contains valid days for adjustment.chargetAdjustSign()CalendarConditiongetSourceCalendar()Returns the source calendar condition.booleanisGroup()Returnstrueif this is a group keyword.booleanisMonthly()Returnstrueif this is a monthly keyword.booleanisRoll()Returnstrueif this is a roll keyword.booleanisStatic()Returnstrueif this is a static keyword.booleanisWeekly()Returnstrueif this is a weekly keyword.booleanisYearly()Returnstrueif this is a yearly keyword.booleanremoveCollision(RollCalendarCollision coll)Removes the specified reaction in case of a collision.protected voidsave(com.uc4.util.XMLDocument doc, org.w3c.dom.Element parent)Saves the keyword under the specified parent elementvoidsetAdjustDays(int adjustDays)Sets the number of days of adjustment.voidsetAdjustmentCalendar(CalendarCondition adjustmentCalendar)Sets the calendar and keyword from which days should be choosen if adjustment is enabled.voidsetAdjustSign(char sign)Sets the sign of the adjust offset.voidsetSourceCalendar(CalendarCondition sourceCalendar)Sets the source calendar condition.- 
Methods inherited from class com.uc4.api.objects.CalendarKeyword
containsDate, equals, getCalendarName, getErrorMessageInsert, getErrorMessageNumber, getErrorText, getName, getPreCalculatedDates, hashCode, invalidateCalculatedDates, loadCalculatedDays, setCalendarName, setErrorMessageInsert, setErrorMessageNumber, setErrorText, setName, toString 
 - 
 
 - 
 
- 
- 
Constructor Detail
- 
RollCalendarKeyword
protected RollCalendarKeyword(org.w3c.dom.Element keyword, java.lang.String string) 
- 
RollCalendarKeyword
public RollCalendarKeyword(UC4ObjectName name, CalendarCondition cond)
Constructs a newRollCalendarKeywordusing the specified source calendar condition.- Parameters:
 name- Name of the calendar keywordcond- Source calendar and keyword
 
 - 
 
- 
Method Detail
- 
collisionIterator
public java.util.Iterator<RollCalendarCollision> collisionIterator()
Returns an iterator overRollCalendarCollision.- Returns:
 - Iterator over reactions in case of collisions
 
 
- 
addCollision
public void addCollision(RollCalendarCollision coll)
Adds aRollCalendarCollisionto the list of reactions in case of collision.- Parameters:
 coll- Reactions in case of collision
 
- 
removeCollision
public boolean removeCollision(RollCalendarCollision coll)
Removes the specified reaction in case of a collision.- Parameters:
 coll- Reactions in case of collision- Returns:
 - True if and only if the RollCalendarCollision was removed from this list of collisions
 
 
- 
collionsSize
public int collionsSize()
Returns the number of entries in the collision list.- Returns:
 - Number of collitions actions
 
 
- 
getAdjustDays
public int getAdjustDays()
Returns the number of days of adjustment.- Returns:
 - Integer containing the day offset
 
 
- 
setAdjustDays
public void setAdjustDays(int adjustDays)
Sets the number of days of adjustment.- Parameters:
 adjustDays- Integer containing the day offset
 
- 
getAdjustmentCalendar
public CalendarCondition getAdjustmentCalendar()
Returns the name and keyword of the calendar which contains valid days for adjustment.- Returns:
 - Calendar name and calendar keyword containing valid days for adjustment
 
 
- 
setAdjustmentCalendar
public void setAdjustmentCalendar(CalendarCondition adjustmentCalendar)
Sets the calendar and keyword from which days should be choosen if adjustment is enabled. The parameteradjustmentCalendarcan be set tonullif no specific calendar with valid days should be used.- Parameters:
 adjustmentCalendar- Calendar name and calendar keyword containing valid days for adjustment
 
- 
getSourceCalendar
public CalendarCondition getSourceCalendar()
Returns the source calendar condition.- Returns:
 - Source calendar condition
 
 
- 
setSourceCalendar
public void setSourceCalendar(CalendarCondition sourceCalendar)
Sets the source calendar condition.- Parameters:
 sourceCalendar- Source calendar condition
 
- 
isStatic
public boolean isStatic()
Description copied from class:CalendarKeywordReturnstrueif this is a static keyword.- Specified by:
 isStaticin classCalendarKeyword- Returns:
 - Boolean containing true in case of a static keyword
 
 
- 
isWeekly
public boolean isWeekly()
Description copied from class:CalendarKeywordReturnstrueif this is a weekly keyword.- Specified by:
 isWeeklyin classCalendarKeyword- Returns:
 - Boolean containing true in case of a weekly keyword
 
 
- 
isMonthly
public boolean isMonthly()
Description copied from class:CalendarKeywordReturnstrueif this is a monthly keyword.- Specified by:
 isMonthlyin classCalendarKeyword- Returns:
 - Boolean containing true in case of a monthly keyword
 
 
- 
isYearly
public boolean isYearly()
Description copied from class:CalendarKeywordReturnstrueif this is a yearly keyword.- Specified by:
 isYearlyin classCalendarKeyword- Returns:
 - Boolean containing true in case of a yearly keyword
 
 
- 
isGroup
public boolean isGroup()
Description copied from class:CalendarKeywordReturnstrueif this is a group keyword.- Specified by:
 isGroupin classCalendarKeyword- Returns:
 - Boolean containing true in case of a group keyword
 
 
- 
isRoll
public boolean isRoll()
Description copied from class:CalendarKeywordReturnstrueif this is a roll keyword.- Specified by:
 isRollin classCalendarKeyword- Returns:
 - Boolean containing true in case of a roll keyword
 
 
- 
setAdjustSign
public void setAdjustSign(char sign)
Sets the sign of the adjust offset.- Parameters:
 sign- Sign '+' or '-'
 
- 
getAdjustSign
public char getAdjustSign()
- Returns:
 - Sign of the adjust offset. Can be + or -
 
 
- 
save
protected void save(com.uc4.util.XMLDocument doc, org.w3c.dom.Element parent)Description copied from class:CalendarKeywordSaves the keyword under the specified parent element- Specified by:
 savein classCalendarKeyword- Parameters:
 doc- XML Documentparent- Parent element
 
 - 
 
 -