Interface OffsetEvent
- All Superinterfaces:
Browsable, Extensible, Identifiable, Operable, OsidObject, OsidRule
An OffsetEvent describes events that are relative to other
events. OffsetEvents may have a fixed or rubber start date as well
as a fixed or rubber end date. A rubber start and end date has a variable
duration based on the starting and ending milestones. An
OffsetEvent with a fixed start date and a fixed duration behaves like a
normal fixed Event .
Creating an OffsetEvent produces an Event that is
based on these offset rules.
-
Method Summary
Modifier and TypeMethodDescriptionGets theEventto which the end of this event is offset.Gets theEvent Idto which the end of this event is offset.Gets the duration of the offset event.Gets the fixed ending time offset.Gets the fixed starting time offset.Gets the fixed start time for this event.Gets theLocation.Gets a descriptive location.Gets the locationId.getOffsetEventRecord(Type offsetEventRecordType) Gets the offset event record corresponding to the givenOffsetEventrecordType.longGets the ending weekday number.longGets the starting weekday number.longGets the ending offset as the nth weekday from the relative event.longGets the starting offset as the nth weekday from the relative event.Gets theIdof the event sponsors.Gets theSponsors.Gets theEventto which the start of this event is offset.Gets theEvent Idto which the start of this event is offset.booleanTests if this offset event is based on a fixed duration.booleanTests if this offset end time based on a fixed period of time.booleanTests if this offset start time based on a fixed period of time.booleanTests if this offset event is based on a fixed start time.booleanTests if a location is associated with this event.booleanTests if this ending time offset is a based on a relative weekday.booleanTests if this starting time offset is a based on a relative weekday.booleanTests if a sponsor is associated with this event.Methods inherited from interface Browsable
getProperties, getPropertiesByRecordTypeModifier and TypeMethodDescriptionGets a list of properties.getPropertiesByRecordType(Type recordType) Gets a list of properties corresponding to the specified record type.Methods inherited from interface Extensible
getRecordTypes, hasRecordTypeModifier and TypeMethodDescriptionGets the record types available in this object.booleanhasRecordType(Type recordType) Tests if this object supports the given recordType.Methods inherited from interface Identifiable
getId, isCurrentMethods inherited from interface Operable
isActive, isDisabled, isEnabled, isOperationalModifier and TypeMethodDescriptionbooleanisActive()Tests if this operable is active.booleanTests if this operable is administravely disabled.booleanTests if this operable is administravely enabled.booleanTests if thisOperableis operational.Methods inherited from interface OsidObject
getDescription, getDisplayName, getGenusType, isOfGenusTypeModifier and TypeMethodDescriptionGets the description associated with this instance of this OSID object.Gets the preferred display name associated with this instance of this OSID object appropriate for display to the user.Gets the genus type of this object.booleanisOfGenusType(Type genusType) Tests if this object is of the given genusType.Methods inherited from interface OsidRule
getConditionRecordTypes, getRule, getRuleId, hasRule
-
Method Details
-
hasFixedStartTime
boolean hasFixedStartTime()Tests if this offset event is based on a fixed start time.- Returns:
trueif this offset is based on a fixed start time,falseotherwise- Compliance:
mandatory- This method must be implemented.
-
getFixedStartTime
DateTime getFixedStartTime()Gets the fixed start time for this event.- Returns:
- the fixed start time
- Throws:
IllegalStateException-hasFixedStartIme()isfalse- Compliance:
mandatory- This method must be implemented.
-
getStartReferenceEventId
Id getStartReferenceEventId()Gets theEvent Idto which the start of this event is offset.- Returns:
- the relative event
Id - Throws:
IllegalStateException-hasFixedStartTime()istrue- Compliance:
mandatory- This method must be implemented.
-
getStartReferenceEvent
Gets theEventto which the start of this event is offset.- Returns:
- the relative event
- Throws:
IllegalStateException-hasFixedStartTime()istrueOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
hasFixedStartOffset
boolean hasFixedStartOffset()Tests if this offset start time based on a fixed period of time.- Returns:
trueif this offset is based on a fixed period of time,falseotherwise- Throws:
IllegalStateException-hasFixedStartTime()istrue- Compliance:
mandatory- This method must be implemented.
-
getFixedStartOffset
Duration getFixedStartOffset()Gets the fixed starting time offset.- Returns:
- the offset
- Throws:
IllegalStateException-hasFixedStartOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
hasRelativeWeekdayStartOffset
boolean hasRelativeWeekdayStartOffset()Tests if this starting time offset is a based on a relative weekday.- Returns:
trueif this offset is based on a relative weekday,falseotherwise- Throws:
IllegalStateException-hasFixedStartOffset()istrue- Compliance:
mandatory- This method must be implemented.
-
getRelativeWeekdayStartOffset
long getRelativeWeekdayStartOffset()Gets the starting offset as the nth weekday from the relative event. Zero is no offset.- Returns:
- the offset
- Throws:
IllegalStateException-hasRelativeWeekdayStartOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
getRelativeStartWeekday
long getRelativeStartWeekday()Gets the starting weekday number. The weekday is based on the calendar type. On the Gregorian calendar, 0 is Sunday.- Returns:
- the weekday number
- Throws:
IllegalStateException-hasRelativeWeekdayStartOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
hasFixedDuration
boolean hasFixedDuration()Tests if this offset event is based on a fixed duration.- Returns:
trueif this offset is based on a fixed duration,falseotherwise- Compliance:
mandatory- This method must be implemented.
-
getFixedDuration
Gets the duration of the offset event.- Parameters:
units- the units of the duration- Returns:
- the duration
- Throws:
IllegalStateException-hasFixedDuration()isfalseNullArgumentException-unitsisnull- Compliance:
mandatory- This method must be implemented.
-
getEndReferenceEventId
Id getEndReferenceEventId()Gets theEvent Idto which the end of this event is offset.- Returns:
- the relative event
Id - Throws:
IllegalStateException-hasFixedDuration()istrue- Compliance:
mandatory- This method must be implemented.
-
getEndReferenceEvent
Gets theEventto which the end of this event is offset.- Returns:
- the relative event
- Throws:
IllegalStateException-hasFixedDuration()istrueOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
hasFixedEndOffset
boolean hasFixedEndOffset()Tests if this offset end time based on a fixed period of time.- Returns:
trueif this offset is based on a fixed period of time,falseotherwise- Throws:
IllegalStateException-hasFixedDuration()istrue- Compliance:
mandatory- This method must be implemented.
-
getFixedEndOffset
Duration getFixedEndOffset()Gets the fixed ending time offset.- Returns:
- the offset
- Throws:
IllegalStateException-hasFixedEndOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
hasRelativeWeekdayEndOffset
boolean hasRelativeWeekdayEndOffset()Tests if this ending time offset is a based on a relative weekday.- Returns:
trueif this offset is based on a relative weekday,falseotherwise- Throws:
IllegalStateException-hasFixedEndOffset()istrue- Compliance:
mandatory- This method must be implemented.
-
getRelativeWeekdayEndOffset
long getRelativeWeekdayEndOffset()Gets the ending offset as the nth weekday from the relative event. Zero is no offset.- Returns:
- the offset
- Throws:
IllegalStateException-hasRelativeWeekdayEndOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
getRelativeEndWeekday
long getRelativeEndWeekday()Gets the ending weekday number. The weekday is based on the calendar type. On the Gregorian calendar, 0 is Sunday.- Returns:
- the weekday number
- Throws:
IllegalStateException-hasRelativeWeekdayEndOffset()isfalse- Compliance:
mandatory- This method must be implemented.
-
getLocationDescription
DisplayText getLocationDescription()Gets a descriptive location.- Returns:
- the location
- Compliance:
mandatory- This method must be implemented.
-
hasLocation
boolean hasLocation()Tests if a location is associated with this event.- Returns:
trueif there is an associated location,falseotherwise- Compliance:
mandatory- This method must be implemented.
-
getLocationId
Id getLocationId()Gets the locationId.- Returns:
- a location
Id - Throws:
IllegalStateException-hasLocation()isfalse- Compliance:
mandatory- This method must be implemented.
-
getLocation
Gets theLocation.- Returns:
- a location
- Throws:
IllegalStateException-hasLocation()isfalseOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
hasSponsors
boolean hasSponsors()Tests if a sponsor is associated with this event.- Returns:
trueif there is an associated sponsor.falseotherwise- Compliance:
mandatory- This method must be implemented.
-
getSponsorIds
IdList getSponsorIds()Gets theIdof the event sponsors.- Returns:
- the sponsor
Ids - Throws:
IllegalStateException-hasSponsors()isfalse- Compliance:
mandatory- This method must be implemented.
-
getSponsors
Gets theSponsors.- Returns:
- the sponsors
- Throws:
IllegalStateException-hasSponsors()isfalseOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getOffsetEventRecord
Gets the offset event record corresponding to the givenOffsetEventrecordType. This method is used to retrieve an object implementing the requested record. TheoffsetEventRecordTypemay be theTypereturned ingetRecordTypes()or any of its parents in aTypehierarchy wherehasRecordType(offsetEventRecordType)istrue.- Parameters:
offsetEventRecordType- the type of the record to retrieve- Returns:
- the offset event record
- Throws:
NullArgumentException-offsetEventRecordTypeisnullOperationFailedException- unable to complete requestUnsupportedException-hasRecordType(offsetEventRecordType)isfalse- Compliance:
mandatory- This method must be implemented.
-