Closed nkuehnel closed 2 weeks ago
I had to borrow the concept from the MultiModeDrtConfigGroup which allows defining a custom supplier for drt config groups for materializing / reading back in configs. The supplier is required for DrtConstraintsSets inside DrtConstraintsParams and needs to be passed to the DrtConfigGroup which is why I added an additional constructor.
It works well but is another change to the drt config group.
Ah and there's a test added that shows how to do it: https://github.com/matsim-org/matsim-libs/blob/57fa8aa5a414519dad374b1e9650b927d3ffb0fc/contribs/drt/src/test/java/org/matsim/contrib/drt/config/ConfigBehaviorTest.java#L92-L167
LGTM!
this is the final change towards more flexible drt optimization constraints - the drt route creator uses a constraint set chooser and constraints calculator to create and update routes.
There are certainly other ways to achieve this, I'm happy for any discussion / feedback.
Use case: