Linked activities across routes

I have a task where some services are linked in such a way that if, say, node A is serviced by vehicle V1, then node B must be serviced by vehicle V2; if A is serviced by V2, B must have V3, and so on. Of course, there are many more nodes and many more vehicles, but you get the idea.
Is there a way to achieve this in jsprit? From what I found so far, the constraints only have access to the route they are in, but know nothing about the other routes. But I would need to access the other ones to see if node A has already been assigned to a vehicle, and then check if B is being assigned to an acceptable vehicle as well.
Cheers!

This is possible but you may need to keep track of the state yourself with the StateManager