Package org.goplanit.service.routed
Interface RoutedTripSchedule
-
- All Superinterfaces:
Cloneable
,Comparable<IdAble>
,ExternalIdAble
,IdAble
,ManagedId
,RoutedTrip
- All Known Implementing Classes:
RoutedTripScheduleImpl
public interface RoutedTripSchedule extends RoutedTrip
The schedule with on or more departures for a routed service as well as the relative timings of each leg for each departure. Each leg timing is in an ordered position, meaning that the first timing represents the first leg of the routed service and the last leg the final leg etc.- Author:
- markr
-
-
Field Summary
-
Fields inherited from interface org.goplanit.service.routed.RoutedTrip
ROUTED_TRIP_ID_CLASS
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description RelativeLegTiming
addRelativeLegSegmentTiming(ServiceLegSegment parentLegSegment, LocalTime duration, LocalTime dwellTime)
Add a new leg's timing to the end of the already registered leg timings.void
clearRelativeLegTimings()
Clear all leg timings from the tripRoutedTripDepartures
getDepartures()
Access to the departures of this scheduleRelativeLegTiming
getRelativeLegTiming(int index)
Collect a leg timing based on its indexint
getRelativeLegTimingsSize()
Collect the number of registered leg timings-
Methods inherited from interface org.goplanit.utils.id.ExternalIdAble
getExternalId, getXmlId, hasExternalId, hasXmlId, setExternalId, setXmlId
-
Methods inherited from interface org.goplanit.utils.id.IdAble
clone, compareTo, getId, idEquals, idHashCode
-
Methods inherited from interface org.goplanit.utils.id.ManagedId
recreateManagedIds, resetChildManagedIdEntities
-
Methods inherited from interface org.goplanit.service.routed.RoutedTrip
getIdClass
-
-
-
-
Method Detail
-
getDepartures
RoutedTripDepartures getDepartures()
Access to the departures of this schedule- Returns:
- departures
-
clearRelativeLegTimings
void clearRelativeLegTimings()
Clear all leg timings from the trip
-
addRelativeLegSegmentTiming
RelativeLegTiming addRelativeLegSegmentTiming(ServiceLegSegment parentLegSegment, LocalTime duration, LocalTime dwellTime)
Add a new leg's timing to the end of the already registered leg timings.- Parameters:
parentLegSegment
- (directed leg) to add to the trip's routeduration
- duration of the leg segmentdwellTime
- at the destination of the leg segment- Returns:
- the added timing
-
getRelativeLegTiming
RelativeLegTiming getRelativeLegTiming(int index)
Collect a leg timing based on its index- Parameters:
index
- to collect- Returns:
- the relative leg timing found
-
getRelativeLegTimingsSize
int getRelativeLegTimingsSize()
Collect the number of registered leg timings- Returns:
- number of relative leg timings registered
-
-