public interface OsidEnabler extends OsidRule, Temporal
OsidEnabler
is used to manage the effectiveness,
enabledness, or operation of an OsidObejct.
The
OsidEnabler
itself is active or inactive When an
OsidEnabler
is active, any OsidObject
mapped to it
is "on." When all OsidEnablers
mapped to an
OsidObject
are inactive, then the OsidObject
is
"off."
The managed OsidObject
may have varying semantics as to
what its on/off status means and in particular, which methods are used to
indicate the effect of an OsidEnabler.
Some axamples:
Operables:
OsidEnablers
effect the
operational status. Temporals:
OsidEnablers
may be used
to extend or shorten the effectiveness of a Temporal
such as an OsidRelationship.
In the case where an OsidEnabler
may cause a
discontinuity in a Temporal,
the OsidEnabler
may cause the creation of new Temporals
to capture the gap
in effectiveness.
For example, An OsidRelationship
that began in 2007 may
be brought to an end in 2008 due to the absence of any active
OsidEnablers.
When an effective OsidEnabler
appears
in 2009, a new OsidRelationship
is created with a starting
effective date of 2009 leaving the existing OsidRelationship
with effective dates from 2007 to 2008.
An OsidEnabler
itself is both a Temporal
and an OsidRule
whose activity status of the object may be
controlled administratively, using a span of effective dates, through an
external rule, or all three. The OsidEnabler
defines a set
of canned rules based on dates, events, and cyclic events.
Modifier and Type | Method and Description |
---|---|
CyclicEvent |
getCyclicEvent()
Gets the cyclic event.
|
Id |
getCyclicEventId()
Gets the cyclic event
Id . |
Resource |
getDemographic()
Gets the demographic resource.
|
Id |
getDemographicId()
Gets the demographic resource
Id . |
Event |
getEvent()
Gets the event.
|
Id |
getEventId()
Gets the event
Id . |
Schedule |
getSchedule()
Gets the schedule.
|
Id |
getScheduleId()
Gets the schedule
Id . |
boolean |
isEffectiveByCyclicEvent()
Tests if the effectiveness of the enabler is governed by a
CyclicEvent. |
boolean |
isEffectiveByEvent()
Tests if the effectiveness of the enabler is governed by an
Event such that the start and end dates of the event govern
the effectiveness. |
boolean |
isEffectiveBySchedule()
Tests if the effectiveness of the enabler is governed by a
Schedule. |
boolean |
isEffectiveForDemographic()
Tests if the effectiveness of the enabler applies to a demographic
resource.
|
getDescription, getDisplayName, getGenusType, isOfGenusType
getId, isCurrent
getRecordTypes, hasRecordType
getProperties, getPropertiesByRecordType
isActive, isDisabled, isEnabled, isOperational
getEndDate, getStartDate, isEffective
boolean isEffectiveBySchedule()
Schedule.
If a schedule exists, it is bounded by the effective
dates of this enabler. If isEffectiveBySchedule()
is
true,
isEffectiveByEvent()
and
isEffectiveByCyclicEvent()
must be false.
true
if the enabler is governed by schedule,
false
otherwisemandatory
- This method must be implemented. Id getScheduleId()
Id
. Id
IllegalStateException
- isEffectiveBySchedule()
is false
mandatory
- This method must be implemented. Schedule getSchedule() throws OperationFailedException
IllegalStateException
- isEffectiveBySchedule()
is false
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. boolean isEffectiveByEvent()
Event
such that the start and end dates of the event govern
the effectiveness. The event may also be a RecurringEvent
in which case the enabler is effective for start and end dates
of each event in the series If an event exists, it is bounded by the
effective dates of this enabler. If isEffectiveByEvent()
is true,
isEffectiveBySchedule()
and isEffectiveByCyclicEvent()
must be false.
true
if the enabler is governed by an event,
false
otherwisemandatory
- This method must be implemented. Id getEventId()
Id
. Id
IllegalStateException
- isEffectiveByEvent()
is false
mandatory
- This method must be implemented. Event getEvent() throws OperationFailedException
IllegalStateException
- isEffectiveByEvent()
is false
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. boolean isEffectiveByCyclicEvent()
CyclicEvent.
If a cyclic event exists, it is evaluated by the
accompanying cyclic time period. If isEffectiveByCyclicEvent()
is true,
isEffectiveBySchedule()
and isEffectiveByEvent()
must be false.
true
if the enabler is governed by a cyclic
event, false
otherwisemandatory
- This method must be implemented. Id getCyclicEventId()
Id
. Id
IllegalStateException
-
isEffectiveByCyclicEvent()
is false
mandatory
- This method must be implemented. CyclicEvent getCyclicEvent() throws OperationFailedException
IllegalStateException
-
isEffectiveByCyclicEvent()
is false
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented. boolean isEffectiveForDemographic()
true
if the rule apples to a demographic.
false
otherwisemandatory
- This method must be implemented. Id getDemographicId()
Id
. Id
IllegalStateException
-
isEffectiveForDemographic()
is false
mandatory
- This method must be implemented. Resource getDemographic() throws OperationFailedException
IllegalStateException
-
isEffectiveForDemographic()
is false
OperationFailedException
- unable to complete requestmandatory
- This method must be implemented.