Send feedback
Stay organized with collections
Save and categorize content based on your preferences.
C++ Reference: class VehicleTypeCurator
This documentation is automatically generated.
Helper class that stores vehicles by their type. Two vehicles have the same
"vehicle type" iff they have the same cost class and start/end nodes.
Method
GetCompatibleVehicleOfType
Return type: int
Arguments:
int type, std::function<bool(int)> vehicle_is_compatible
Searches for the best compatible vehicle of the given type, i.e. the first
vehicle v of type 'type' for which vehicle_is_compatible(v) returns true.
If a compatible vehicle is found, its index is removed from
vehicles_per_vehicle_class_ and returned.
Returns -1 otherwise.
GetVehicleOfType
Return type: int
Arguments: int type
NumTypes
Return type: int
ReinjectVehicleOfClass
Return type: void
Arguments: int vehicle, int vehicle_class,
int64 fixed_cost
Reset
Return type: void
Type
Return type: int
Arguments: int vehicle
VehicleTypeCurator
Return type: explicit
Arguments:
const RoutingModel::VehicleTypeContainer& vehicle_type_container
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2021-01-05 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples / code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Need to tell us more?