Interface ILogicEntityRoute

All Superinterfaces:
Cloneable, Serializable
All Known Implementing Classes:
LogicEntityRoute

public interface ILogicEntityRoute extends Cloneable, Serializable
This Interface provides the methods to get information about certain Route IOptimizationElements like the INodes, the IResource, getting the IDutyHours and much more. IEntityInvokedOperatorController
Since:
08/08/2018
Version:
13/02/2020
Author:
DNA
  • Method Details

    • getOptimizableElementIterator

      ListIterator<IOptimizationElement> getOptimizableElementIterator()
      Gets the ListIterator for the optimizable Elements.
      Returns:
      the iterator
    • getNoneOptimizableElementIterator

      ListIterator<IOptimizationElement> getNoneOptimizableElementIterator()
      Gets the ListIterator for the NoneOptimizableElements.
      Returns:
      the iterator
    • getRouteOptimizableElement

      IOptimizationElement getRouteOptimizableElement(int index)
      Gets the IOptimizationElement by the index which was given by the order of the Elements added.
      Parameters:
      index - the int index
      Returns:
      the Element
    • getRouteOptimizableElements

      List<IOptimizationElement> getRouteOptimizableElements()
      Gets all the IOptimizationElements of the Route, including all the Nodes and Resources.
      Returns:
      the list of Elements
    • setRouteOptimizableElements

      void setRouteOptimizableElements(List<IOptimizationElement> elements)
      Sets the IOptimizationElements.This method should NOT used directly only together with copy.
      Parameters:
      elements - the new route elements
    • getCurrentVisitingResource

      IResource getCurrentVisitingResource()
      Gets the IResource that is visiting this Route.
      Returns:
      the object IResource
    • getCurrentVisitingResourceWorkingHoursIndex

      int getCurrentVisitingResourceWorkingHoursIndex()
      Gets the index of the IWorkingHours of the visiting IResource.
      Returns:
      the index
    • getRouteTermination

      IOptimizationElement getRouteTermination()
      Gets the IOptimizationElement where the Route will end.

      If Route termination has not been overwritten it will be at the location of the IResource or at an one night stay Node. If Route termination has been overwritten it will be at the anchorNode.

      Returns:
      the Element where the Route terminates
    • setRouteTermination

      void setRouteTermination(IOptimizationElement terminationItem)
      Sets the IOptimizationElement where the Route will end.
      Parameters:
      terminationItem - the iOptimizationElement
    • getRouteStart

      IOptimizationElement getRouteStart()
      Gets the IOptimizationElement where the Route starts.
      Returns:
      the start of the Route
    • setRouteStart

      void setRouteStart(IOptimizationElement startItem)
      Sets IOptimizationElement where the route will start.
      Parameters:
      startItem - the iOptimizationElement where the route has to start
    • getRouteStartTime

      long getRouteStartTime()
      Gets the Route start time in milliseconds since 01.01.1970.
      Returns:
      the milliseconds since Route start
    • addOptimizableElement

      void addOptimizableElement(IOptimizationElement element)
      Adds an IOptimizationElement like an IResource or an INode to the Route.
      Parameters:
      element - iOptimizationElement to add
    • addOptimizableElement

      void addOptimizableElement(IOptimizationElement element, int index)
    • removeOptimizableElement

      IOptimizationElement removeOptimizableElement(IOptimizationElement element)
    • removeOptimizableElement

      IOptimizationElement removeOptimizableElement(int index)
    • setCurrentVisitingResource

      void setCurrentVisitingResource(IResource res, int workingHourIndex)
    • removeAllFromOptimizableElements

      boolean removeAllFromOptimizableElements(List<? extends IOptimizationElement> removeList)
    • getRouteCostAndViolationController

      ILogicRouteCostAndViolationController getRouteCostAndViolationController()
    • getRouteElementsDetailController

      ILogicRouteElementDetailController getRouteElementsDetailController()
    • getJoinedDetailController

      IJoinedRouteDetailController getJoinedDetailController()
    • toString

      String toString()
      Overrides:
      toString in class Object
    • getRouteId

      int getRouteId()
    • getRouteOptimizableElementCount

      int getRouteOptimizableElementCount()
    • isUnassessed

      boolean isUnassessed()
    • setIsUnassessed

      void setIsUnassessed(boolean isUnassessed)
    • getOptimizableElementsSubList

      List<IOptimizationElement> getOptimizableElementsSubList(int fromIndex, int toIndex)
    • addAllToOptimizableElements

      boolean addAllToOptimizableElements(int index, List<? extends IOptimizationElement> addList)
    • addAllToOptimizableElements

      boolean addAllToOptimizableElements(List<? extends IOptimizationElement> addList)
    • copy

    • setCurrentVisitingResourceWorkingHoursIndex

      void setCurrentVisitingResourceWorkingHoursIndex(int index)
    • setRouteId

      void setRouteId(int routeId)
    • clearOptimizableElements

      void clearOptimizableElements()
    • clearNoneOptimizableElements

      void clearNoneOptimizableElements()
    • isLastOptimizableElementInRoute

      boolean isLastOptimizableElementInRoute(IOptimizationElement element)
    • isFirstOptimizableElementInRoute

      boolean isFirstOptimizableElementInRoute(IOptimizationElement element)
    • addRoutePillar

      void addRoutePillar(IPillarNode pillar)
    • hasRoutePillars

      boolean hasRoutePillars()
    • getRoutePillars

      List<IPillarNode> getRoutePillars()
    • getRouteDutyHours

      IDutyHours getRouteDutyHours()
      Returns the LogicEntityRoute.currentRouteDutyHours of this LogicEntityRoute.
      Returns:
      the LogicEntityRoute.currentRouteDutyHours
    • initRouteWorkingHours

      void initRouteWorkingHours()
    • setRoutePillars

      void setRoutePillars(List<IPillarNode> pillars)
    • setRequestElementDetails

      void setRequestElementDetails(boolean requestDetails)
      Sets result requested resulting in the ILogicRouteElementDetailItem being saved and being accessable afterwards. This will seen by the cost assessor. After one request the ILogicEntityRoute automatically is set back to no request.
      Parameters:
      requestDetails - the boolean whether the ILogicRouteElementDetailItem should be saved
    • isRequestElementDetails

      boolean isRequestElementDetails()
    • isFinalized

      boolean isFinalized()
    • getRouteNoneOptimizableElements

      List<IOptimizationElement> getRouteNoneOptimizableElements()
    • setRouteNoneOptimizableElements

      void setRouteNoneOptimizableElements(List<IOptimizationElement> elements)
    • addAllToNoneOptimizableElements

      boolean addAllToNoneOptimizableElements(List<IOptimizationElement> routeOptimizableElements)
    • addRoutePillars

      void addRoutePillars(List<IPillarNode> pillars)
    • getRouteStopTime

      long getRouteStopTime()
    • removeRoutePillar

      IPillarNode removeRoutePillar(IPillarNode pillar)
    • getEffectiveRouteStartTime

      long getEffectiveRouteStartTime()
    • getEffectiveRouteStopTime

      long getEffectiveRouteStopTime()
    • getMaxWorkingHours

      double getMaxWorkingHours()
    • getMaxDistanceKilometer

      double getMaxDistanceKilometer()
    • addRoutePillar

      void addRoutePillar(IPillarNode pillar, int index)
    • setEffectivePillarLatestArrivalMap

      void setEffectivePillarLatestArrivalMap(Map<String,Long> effectivePillarLatestArrivalMap)
    • getPillarLatestEffectiveArrival

      long getPillarLatestEffectiveArrival(IPillarNode p)
    • isScheduled

      boolean isScheduled()
    • setIsScheduled

      void setIsScheduled(boolean isScheduled)
    • removeRoutePillars

      void removeRoutePillars(List<IPillarNode> pillars)
    • clearRoutePillars

      void clearRoutePillars()
    • setRouteCostAndViolationController

      void setRouteCostAndViolationController(ILogicRouteCostAndViolationController controller)
    • addOptionalOptimizableElement

      void addOptionalOptimizableElement(IOptimizationElement optionalElement)
    • hasSameElementsStructure

      boolean hasSameElementsStructure(ILogicEntityRoute compareRoute)
    • setRouteOptionalOptimizableElements

      void setRouteOptionalOptimizableElements(List<IOptimizationElement> elements)
    • getRouteOptionalOptimizableElements

      List<IOptimizationElement> getRouteOptionalOptimizableElements()
    • addAllToOptionalOptimizableElements

      boolean addAllToOptionalOptimizableElements(List<IOptimizationElement> addList)
    • hasSameElementsStructureIgnorePillars

      boolean hasSameElementsStructureIgnorePillars(ILogicEntityRoute compareRoute, boolean doIgnorePillars)
    • removeRoutePillar

      IPillarNode removeRoutePillar(int index)
    • isClosedRoute

      boolean isClosedRoute()
      Returns whether LogicEntityRoute.getCurrentWorkingHours() is closed or not.
      Returns:
      boolean, default value false. Returns true if IWorkingHours.isClosedRoute() has been set to true by using IWorkingHours.setIsClosedRoute(boolean).
    • markAsToBeRemoved

      void markAsToBeRemoved()
    • isMarkedToBeRemoved

      boolean isMarkedToBeRemoved()
    • getRouteTimeMillis

      long getRouteTimeMillis()
    • getMaxRouteStartReductionTimeMillis

      Optional<Long> getMaxRouteStartReductionTimeMillis()
    • getMaxRouteStartReductionTimeMillisPillar

      Optional<Long> getMaxRouteStartReductionTimeMillisPillar()
    • isReductionTimeIncludedInWorkingTime

      Optional<Boolean> isReductionTimeIncludedInWorkingTime()
    • isReductionTimeOnlyUsedForDriving

      Optional<Boolean> isReductionTimeOnlyUsedForDriving()
    • isReductionTimeOnlyUsedForDrivingPillar

      Optional<Boolean> isReductionTimeOnlyUsedForDrivingPillar()
    • getFlexTimeMillis

      Optional<Long> getFlexTimeMillis()
    • getMaxPillarAfterHoursTime

      Optional<Long> getMaxPillarAfterHoursTime()
    • getTotalRouteDistanceMeter

      double getTotalRouteDistanceMeter()
    • getMaxFreePostWorkDrivingTerminationTimeMillis

      Optional<Long> getMaxFreePostWorkDrivingTerminationTimeMillis()
    • hasOverriddenRouteStart

      boolean hasOverriddenRouteStart()
    • hasOverriddenRouteTermination

      boolean hasOverriddenRouteTermination()
    • initRouteWorkingHours

      void initRouteWorkingHours(IDutyHours fakeHours)
    • getPillarLatestEffectiveOffsetArrival

      long getPillarLatestEffectiveOffsetArrival(IPillarNode p)
    • putEffectivePillarLatestArrivalOffset

      long putEffectivePillarLatestArrivalOffset(IPillarNode p, Long valueMillis)
    • getPillarEffectiveLatestArrivalMinusStartMillis

      long getPillarEffectiveLatestArrivalMinusStartMillis(IPillarNode p)
    • getPillarLatestEffectiveArrivalOffsetCorrected

      long getPillarLatestEffectiveArrivalOffsetCorrected(IPillarNode p)
    • setEffectivePillarLatestArrivalOffsetMap

      void setEffectivePillarLatestArrivalOffsetMap(Map<String,Long> effectivePillarLatestArrivalOffsetMap)
    • getEffectivePillarLatestArrivalOffsetMap

      Map<String,Long> getEffectivePillarLatestArrivalOffsetMap()
    • clearOptionalOptimizableElements

      void clearOptionalOptimizableElements()
    • getQualifications

      Map<Class<? extends IQualification>,IQualification> getQualifications()
    • addFlag

      void addFlag(LogicEntityRouteFlag flag)
    • getFlags

    • setFirstGeoElementWithinRoute

      void setFirstGeoElementWithinRoute(IOptimizationElement firstGeoLocationElementWithinRoute)
    • setLastGeoElementWithinRoute

      void setLastGeoElementWithinRoute(IOptimizationElement lastGeoLocationElementWithinRoute)
    • getFirstGeoElementWithinRoute

      IOptimizationElement getFirstGeoElementWithinRoute()
    • getLastGeoElementWithinRoute

      IOptimizationElement getLastGeoElementWithinRoute()
    • getAllElements

      List<IOptimizationElement> getAllElements()
    • setIsInactive

      void setIsInactive(boolean isInactive)
    • isInactive

      boolean isInactive()
    • setIsLockedDown

      void setIsLockedDown(boolean isLockedDown)
    • isLockedDown

      boolean isLockedDown()
    • getLoadController

      ILoadController getLoadController()
    • setLoadController

      void setLoadController(ILoadController copy)
    • getResourceDepot

      Optional<IResourceDepot> getResourceDepot()
    • getEffectivePillarLatestArrivalMap

      Map<String,Long> getEffectivePillarLatestArrivalMap()
    • getRouteOptimizableElementsIncludingSubsequentNodes

      List<IOptimizationElement> getRouteOptimizableElementsIncludingSubsequentNodes()
    • removeAllFromOptimizableElementsInlcudingSubsequentNodes

      boolean removeAllFromOptimizableElementsInlcudingSubsequentNodes(List<IOptimizationElement> removeList)
    • getRouteClusterController

      IClusterController getRouteClusterController()
    • setRouteClusterController

      void setRouteClusterController(IClusterController routeClusterController)
    • getRouteStartShiftMillisHook

      Optional<Long> getRouteStartShiftMillisHook()
    • getConnectionHook

      Optional<ReducedNodeEdgeConnectorItem> getConnectionHook(String toId)
    • isOnlyApplyFreePostWorkDrivingOnOvertime

      Optional<Boolean> isOnlyApplyFreePostWorkDrivingOnOvertime()
    • getElement

      Optional<IOptimizationElement> getElement(String id, boolean ignoreStartEnd)
    • hasNode

      boolean hasNode(String nodeId, boolean ignoreStartEnd)
    • getLastLockdownStopTime

      Optional<Long> getLastLockdownStopTime()
    • setLastLockdownStopTime

      void setLastLockdownStopTime(Optional<Long> lastLockdownStopTime)
    • setAdditionalRouteStartOffset

      void setAdditionalRouteStartOffset(Optional<Long> offsetMillisOpt)
    • getAdditionalRouteStartOffset

      Optional<Long> getAdditionalRouteStartOffset()
    • getAllNodes

      Set<IOptimizationElement> getAllNodes()