|
Oracle Fusion Applications Java API Reference for Oracle Enterprise Scheduler Service 11g Release 1 (11.1.1.6) E20742-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.as.scheduler.BaseMetadata<ExclusionsDefinition> oracle.as.scheduler.ExclusionsDefinition
public class ExclusionsDefinition
Used to represent a collection of Exclusion
objects as
a single unit.
Instances of ExclusionsDefinition are persisted in the metadata repository which
makes it a sharable object across Schedule
definitions.
An example is list of holidays represented as one instance of ExclusionsDefinition
object that contains all the individual holidays represented by instances
of Exclusion
class. A Schedule
then refer to this holidays
to skip any occurrences that happen on any of these holidays.
Exclusion
,
Schedule
,
Serialized FormConstructor Summary | |
---|---|
ExclusionsDefinition(java.lang.String name,
java.lang.String description,
java.util.Collection<Exclusion> exclusions)
Constructs a new instance with the given collection of exclusions. |
|
ExclusionsDefinition(java.lang.String name,
java.lang.String description,
java.util.Collection<Exclusion> exclusions,
MetadataObjectId objectId)
Constructs a new instance. |
|
ExclusionsDefinition(java.lang.String name,
java.lang.String displayNameKey,
java.lang.String descriptionKey,
java.util.Collection<Exclusion> exclusions,
java.lang.String[] resourceBundleIDs)
Constructs a new instance with the given collection of exclusions. |
Method Summary | |
---|---|
void |
addExclusion(Exclusion exclusion)
Add an exclusion to this object. |
ExclusionsDefinition |
clone(java.lang.String newName)
|
boolean |
equals(java.lang.Object obj)
Compares an object for equality with this ExclusionsDefinition object. |
static ExclusionsDefinition |
from(javax.management.openmbean.CompositeData cd)
Create an instance of the model specific class out of an associated CompositeData instance |
BaseMetadataType<ExclusionsDefinition> |
getBaseMetadataType()
|
java.util.Collection<Exclusion> |
getExclusions()
Returns the list of exclusions of this object. |
protected ExclusionsDefinition |
getSelf()
|
boolean |
isExcluded(java.util.Calendar start,
java.util.Calendar date)
Check if a given date fall in the list of exclusions contained within this ExclusionsDefinition instance. |
void |
removeExclusion(Exclusion exclusion)
Method to remove an Exclusion from this ExclusionsDefinition object. |
void |
setExclusions(java.util.Collection<Exclusion> exclusions)
Sets the list of exclusions of this object. |
javax.management.openmbean.CompositeData |
toCompositeData(javax.management.openmbean.CompositeType ct)
|
static javax.management.openmbean.CompositeType |
toCompositeType()
Returns the CompositeType that describes this model specific class |
protected void |
validateCustom()
Validates this instance of ExclusionsDefinition. |
Methods inherited from class oracle.as.scheduler.BaseMetadata |
---|
from, getDescription, getDescriptionKey, getDisplayName, getDisplayNameKey, getMessages, getMetadataObjectId, getName, getResourceBundles, hashCode, localize, setDescription, setDescriptionKey, setDisplayName, setDisplayNameKey, setResourceBundles, toCompositeData, toString, validate |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ExclusionsDefinition(java.lang.String name, java.lang.String description, java.util.Collection<Exclusion> exclusions)
name
- - name for this instance. It cannot be null. The name is also
used as the default display name unless otherwise specifially set.description
- - optional description string.exclusions
- - collection of exclusions instances for the new instance.public ExclusionsDefinition(java.lang.String name, java.lang.String displayNameKey, java.lang.String descriptionKey, java.util.Collection<Exclusion> exclusions, java.lang.String[] resourceBundleIDs)
name
- -- name for this instance. It cannot be null. The name is also
used as the default display name unless otherwise specifially set.displayNameKey
- - the key of the entry in the resourcebundles to lookup the display name.
OptionaldescriptionKey
- - the key of the entry in the resourcebundles to lookup the description.
Optional.exclusions
- - collection of exclusions instances for the new instance.resourceBundleIDs
- -- an array of resource bundle id, Optionalpublic ExclusionsDefinition(java.lang.String name, java.lang.String description, java.util.Collection<Exclusion> exclusions, MetadataObjectId objectId)
MetadataService
to populate the unique
identifier of this object(definition) within the metadata repository.
name
- - name for this instance. It cannot be null.description
- - optional description string.exclusions
- - collection of exclusions instances for the new instance.objectId
- - unique identifier of this object in the metadata repository.
The identifier is set which this object is retrieved via MetadataService
.Method Detail |
---|
public void addExclusion(Exclusion exclusion)
exclusion
- - instance of Exclusion to be added to this object.public void removeExclusion(Exclusion exclusion)
exclusion
- - the Exclusion instance to be removed from the
list of exclusions contained in this object.public java.util.Collection<Exclusion> getExclusions()
public void setExclusions(java.util.Collection<Exclusion> exclusions)
exclusions
- - a collection containing the list of exclusions to be set for this object.public boolean isExcluded(java.util.Calendar start, java.util.Calendar date)
ExclusionsDefinition
instance. If
found, it indicates that the given date must be skipped or
excluded. The method takes a starting time as an argument
that is used to generate occurrence if any of the Exclusion
contained in this object is based on Recurrence
start
- - the start time for any recurrence based Exclusion.date
- - the date to be checked for exclusion.
protected void validateCustom() throws ValidationException
The method performs
checks that are possible on this object. It does not ensure
the existence of objects referenced by this definition. Such
references and related validations are done by the MetadataService
at the time of object persistence. MetadataService
also calls this method to ensure only valid objects are persisted.
validateCustom
in class BaseMetadata<ExclusionsDefinition>
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 ExclusionsDefinition.
public static javax.management.openmbean.CompositeType toCompositeType()
public javax.management.openmbean.CompositeData toCompositeData(javax.management.openmbean.CompositeType ct)
toCompositeData
in class BaseMetadata<ExclusionsDefinition>
public static ExclusionsDefinition from(javax.management.openmbean.CompositeData cd) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
protected ExclusionsDefinition getSelf()
getSelf
in class BaseMetadata<ExclusionsDefinition>
public BaseMetadataType<ExclusionsDefinition> getBaseMetadataType()
getBaseMetadataType
in class BaseMetadata<ExclusionsDefinition>
public ExclusionsDefinition clone(java.lang.String newName)
clone
in class BaseMetadata<ExclusionsDefinition>
|
Oracle Fusion Applications Java API Reference for Oracle Enterprise Scheduler Service 11g Release 1 (11.1.1.6) E20742-03 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |