ReverseSearch field is now on StreetRouter - #296
Conversation
Instead of ProfileRequest
abyrd
left a comment
There was a problem hiding this comment.
Revisiting this in October 2020, we're no longer using point to point routing much and I'm trying to understand what exactly this change does. It seems like this is making forward and backward searches a property of an individual street search, rather than something that is set across an entire request. This would facilitate doing several searches in different directions within a single request.
| transportNetwork); | ||
| } else { | ||
| streetPath = new StreetPath(state, transportNetwork, false); | ||
| streetPath = new StreetPath(state, transportNetwork, streetRouter.reverseSearch); //reverse search is false |
There was a problem hiding this comment.
Here and on new L125 it's not clear to me why we're replacing hard-coded booleans with variables, accompanied with comments that state the values of those variables are constants.
| request.reverseSearch = false; | ||
| for (Map.Entry<Integer, List<Transfer>> entry: transfersWithSameStart.entrySet()) { | ||
| StreetRouter streetRouter = new StreetRouter(transportNetwork.streetLayer); | ||
| //reverse search is false |
There was a problem hiding this comment.
Again here upon first reading I don't understand the comments asserting that certain values are true or false.
|
Accidentally closed when cleaning up branches. I would like to revisit these old pull requests and determine whether they're still relevant. |
Instead of ProfileRequest
Since I wasn't able to make tests for change. I tested with comparing two saved requests.
Times, distances and paths are the same also for Bike rental and P+R.