|
Oracle Fusion Middleware Java API Reference for Oracle Enterprise Scheduler Service 11g Release 1 (11.1.1.6.2) E26229-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.as.scheduler.Exclusion
public class Exclusion
Date/time instances that are excluded from the occurrences of a Schedule.
Instance of Exclusion can be added to the ExclusionsDefinition
that contains the list of such exclusion instances. One or more ExclusionsDefinition
objects are then referred by the Schedule.
An example would be the list of holidays. This list of holidays can be defined as an ExclusionsDefinition
object where each holiday is represented by an instance of Exclusion
Exclusion can be created with an ExplicitDate
or with an Recurrence
object. The Recurrence
can represent one specific date such as Thanksgiving or a recurring pattern.
RecurrenceFields
, Recurrence
, ExplicitDate
, ExclusionsDefinition
, Schedule
, Serialized FormConstructor Summary | |
---|---|
Exclusion(java.lang.String name, ExplicitDate date) Constructs a new instance representing the given explicit date. |
|
Exclusion(java.lang.String name, Recurrence recur) Constructs a new instance representing the given recurrence. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj) Compares an object for equality with this Exclusion object. |
ExplicitDate |
getExplicitDate() Returns the explicit date this Exlusions object represents. |
java.lang.String |
getName() Returns the name of this Exlusions object. |
Recurrence |
getRecurrence() Returns the recurrence of this Exclusion object. |
int |
hashCode() Returns the hash code value of this Exclusion object. |
boolean |
isExcluded(java.util.Calendar start, java.util.Calendar date) Method to check if a given date is contained in this Exclusion. |
void |
setExplicitDate(ExplicitDate date) Sets the explicit date of this Exlusions object. |
void |
setName(java.lang.String name) Sets the name of this Exlusions object. |
void |
setRecurrence(Recurrence recur) Sets the recurrence of this Exlusion object. |
void |
validate() Validates this instance of Exclusion to make sure it contains valid Recurrence or ExplicitDate . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Exclusion(java.lang.String name, ExplicitDate date)
name
- - optional name to be given to the Exclusion.date
- - the date this Exclusion represent.public Exclusion(java.lang.String name, Recurrence recur)
name
- - optional name to be given to the Exclusion.recur
- - the recurrence this Exclusion represent.Method Detail |
---|
public java.lang.String getName()
public void setName(java.lang.String name)
public void setExplicitDate(ExplicitDate date) throws UnsupportedOperationException
date
- - explicit dat to be set for this object.UnsupportedOperationException
- - thrown if this object already has a recurrence set.public ExplicitDate getExplicitDate()
public void setRecurrence(Recurrence recur) throws UnsupportedOperationException
recur
- - the instance of Recurrence to be set for this object.UnsupportedOperationException
- - thrown if this object already has an explicit date set.public Recurrence getRecurrence()
public boolean isExcluded(java.util.Calendar start, java.util.Calendar date)
If a given date is present, it indicates that the specific date must be excluded. The method also requires a start time if this Exclusion instance is based on Recurrence
The start time is the time from which the contained recurrence will start generating occurrences to check if the specified date is one of the occurrence or not. The method stops generating occurrence when the given date matches one of the generated occurrence or as soon as the generated occurrence goes beyond (after) the given date.
start
- - used as the starting point of this Exclusion is based on Recurrence
. If null, the underlying Recurrence
will use the current timestamp to generate occurrences.date
- - the date/time to be checked for exclusion.public void validate() throws ValidationException
Recurrence
or ExplicitDate
. This method also gets called via ExclusionsDefinition
during persistence into metadata repository.ValidationException
- - thrown if any invalid data is detected.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- - the object to compare with this Exclusion.public int hashCode()
hashCode
in class java.lang.Object
|
Oracle Fusion Middleware Java API Reference for Oracle Enterprise Scheduler Service 11g Release 1 (11.1.1.6.2) E26229-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |