Package com.uc4.api.objects
Class RollCalendarCollision
- java.lang.Object
-
- com.uc4.api.objects.RollCalendarCollision
-
public class RollCalendarCollision extends java.lang.Object
This class represents a reaction to a collision for roll calendar keywords.
-
-
Constructor Summary
Constructors Modifier Constructor Description RollCalendarCollision(CalendarCondition collisionCalendar, int offset)
Deprecated.Use RollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar) insteadRollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar)
Constructs a newRollCalendarCollision
.RollCalendarCollision(CalendarCondition collisionCalendar, int offset, CalendarCondition inCalendar)
Deprecated.Use RollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar) insteadprotected
RollCalendarCollision(org.w3c.dom.Element row)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
int
getAdjustDays()
Returns the number of days of adjustment.char
getAdjustSign()
CalendarCondition
getCollisionCalendar()
Returns the calendar object and keyword with which collisions may occur.CalendarCondition
getInCalendar()
Returns the calendar keyword whose area may be used when moving days.int
getOffset()
Deprecated.use getAdjustSign() and getAdjustSign() insteadint
hashCode()
void
setAdjustDays(int adjustDays)
Sets the number of days of adjustment.void
setAdjustSign(char sign)
Sets the sign of the adjust offset.void
setCollisionCalendar(CalendarCondition collisionCalendar)
Sets the calendar object and keyword with which collisions may occur.void
setInCalendar(CalendarCondition inCalendar)
Sets the calendar keyword whose area may be used when moving days.void
setOffset(int offset)
Deprecated.use setAdjustSign() and setAdjustSign() insteadprotected void
store(org.w3c.dom.Element row)
java.lang.String
toString()
-
-
-
Constructor Detail
-
RollCalendarCollision
@Deprecated public RollCalendarCollision(CalendarCondition collisionCalendar, int offset)
Deprecated.Use RollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar) insteadConstructs a newRollCalendarCollision
. Offset can be set to0
if skip should be used as action.- Parameters:
collisionCalendar
- Calendar object and keyword with which collisions may occuroffset
- Positive or negative integer containg the number of days
-
RollCalendarCollision
@Deprecated public RollCalendarCollision(CalendarCondition collisionCalendar, int offset, CalendarCondition inCalendar)
Deprecated.Use RollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar) insteadConstructs a newRollCalendarCollision
. Offset can be set to0
if skip should be used as action.- Parameters:
collisionCalendar
- Calendar object and keyword with which collisions may occuroffset
- Positive or negative integer containg the number of daysinCalendar
- Specify a particular Calendar keyword whose area may be used, can be null
-
RollCalendarCollision
public RollCalendarCollision(CalendarCondition collisionCalendar, int adjustDays, char sign, CalendarCondition inCalendar)
Constructs a newRollCalendarCollision
. Offset can be set to0
if skip should be used as action.- Parameters:
collisionCalendar
- Calendar object and keyword with which collisions may occuradjustDays
- Positive integer containg the number of dayssign
- Action (+,- or S for Skip)inCalendar
- Specify a particular Calendar keyword whose area may be used, can be null
-
RollCalendarCollision
protected RollCalendarCollision(org.w3c.dom.Element row)
-
-
Method Detail
-
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
-
setAdjustSign
public void setAdjustSign(char sign)
Sets the sign of the adjust offset.- Parameters:
sign
- Sign '+', '-' or 'S' (skip)
-
getAdjustSign
public char getAdjustSign()
- Returns:
- Sign of the adjust offset. Can be '+', '-' or 'S' for Skip
-
getCollisionCalendar
public CalendarCondition getCollisionCalendar()
Returns the calendar object and keyword with which collisions may occur.- Returns:
- Calendar object and keyword with which collisions may occur
-
setCollisionCalendar
public void setCollisionCalendar(CalendarCondition collisionCalendar)
Sets the calendar object and keyword with which collisions may occur.- Parameters:
collisionCalendar
- Calendar object and keyword with which collisions may occur
-
getInCalendar
public CalendarCondition getInCalendar()
Returns the calendar keyword whose area may be used when moving days.- Returns:
- Calendar keyword whose area may be used when moving days
-
setInCalendar
public void setInCalendar(CalendarCondition inCalendar)
Sets the calendar keyword whose area may be used when moving days. The parameterinCalendar
can be set tonull
if no area should be considered when moving days.- Parameters:
inCalendar
- Calendar keyword whose area may be used when moving days
-
getOffset
@Deprecated public int getOffset()
Deprecated.use getAdjustSign() and getAdjustSign() insteadReturns the offset in days.- Returns:
- Offset in days
-
setOffset
@Deprecated public void setOffset(int offset)
Deprecated.use setAdjustSign() and setAdjustSign() insteadSets the offset in days.- Parameters:
offset
- Offset in days
-
store
protected void store(org.w3c.dom.Element row)
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-