private void updatePendingNodes(final int newLandmarkIndex,final RouterPriorityQueue<Node> pendingNodes){
  final List<Double> newEstRemTravCosts=new ArrayList<>();
  final List<Node> nodesToBeUpdated=new ArrayList<>();
  final InternalLandmarkData landmarkData=new InternalLandmarkData();
  for (  Node node : pendingNodes) {
    final AStarNodeData role=getData(node);
    final PreProcessLandmarks.LandmarksData ppRole=preprocess.getNodeData(node);
    landmarkData.setDelegate(ppRole);
    final double newEstRemTravCost=estimateRemainingTravelCost(landmarkData,newLandmarkIndex);
    if (newEstRemTravCost > role.getExpectedRemainingCost()) {
      nodesToBeUpdated.add(node);
      newEstRemTravCosts.add(newEstRemTravCost);
    }
  }
  for (  Node node : nodesToBeUpdated) {
    pendingNodes.remove(node);
  }
  for (int i=0; i < nodesToBeUpdated.size(); i++) {
    final Node node=nodesToBeUpdated.get(i);
    final AStarNodeData data=getData(node);
    data.setExpectedRemainingCost(newEstRemTravCosts.get(i));
    pendingNodes.add(node,getPriority(data));
  }
}

private void updatePendingNodes ( final int newLandmarkIndex , final RouterPriorityQueue < Node > pendingNodes ) { final List < Double > newEstRemTravCosts = new ArrayList < > ( ) ; final List < Node > nodesToBeUpdated = new ArrayList < > ( ) ; final InternalLandmarkData landmarkData = new InternalLandmarkData ( ) ; for ( Node node : pendingNodes ) { final AStarNodeData role = getData ( node ) ; final PreProcessLandmarks . LandmarksData ppRole = preprocess . getNodeData ( node ) ; landmarkData . setDelegate ( ppRole ) ; final double newEstRemTravCost = estimateRemainingTravelCost ( landmarkData , newLandmarkIndex ) ; if ( newEstRemTravCost > role . getExpectedRemainingCost ( ) ) { nodesToBeUpdated . add ( node ) ; newEstRemTravCosts . add ( newEstRemTravCost ) ; } } for ( Node node : nodesToBeUpdated ) { pendingNodes . remove ( node ) ; } for ( int i = 0 ; i < nodesToBeUpdated . size ( ) ; i ++ ) { final Node node = nodesToBeUpdated . get ( i ) ; final AStarNodeData data = getData ( node ) ; data . setExpectedRemainingCost ( newEstRemTravCosts . get ( i ) ) ; pendingNodes . add ( node , getPriority ( data ) ) ; } }
if a landmark has been added to the set of the active landmarks , this function re - evaluates the estimated remaining travel time based on the new set of active landmarks of the nodes contained in pendingnodes . if this estimation improved , the node ' s position in the pendingnodes queue is updated .
