Package globus.glroute
Class CostingOptions.MotorScooter
java.lang.Object
globus.glroute.CostingOptions
globus.glroute.CostingOptions.MotorScooter
- Enclosing class:
- CostingOptions
Options for motor scooter mode
-
Nested Class Summary
Nested classes/interfaces inherited from class globus.glroute.CostingOptions
CostingOptions.Auto, CostingOptions.Bicycle, CostingOptions.Motorcycle, CostingOptions.MotorScooter, CostingOptions.Pedestrian, CostingOptions.Penalties, CostingOptions.Road, CostingOptions.Straight, CostingOptions.Truck, CostingOptions.Vehicle
-
Field Summary
Modifier and TypeFieldDescriptionboolean
Changes the metric to quasi-shortest, i.e.float
Top speed the motorized scooter can go.float
A rider's desire to tackle hills in their routes.float
A rider's propensity to use primary roads. -
Constructor Summary
-
Method Summary
Methods inherited from class globus.glroute.CostingOptions
getJson, initFromJson
-
Field Details
-
topSpeed
public float topSpeedTop speed the motorized scooter can go. Used to avoid roads with higher speeds than this value. For motor_scooter this value must be between 20 and 120 KPH. The default value is 45 KPH (~28 MPH) -
usePrimary
public float usePrimaryA rider's propensity to use primary roads. This is a range of values from 0 to 1, where 0 attempts to avoid primary roads, and 1 indicates the rider is more comfortable riding on primary roads. Based on the use_primary factor, roads with certain classifications and higher speeds are penalized in an attempt to avoid them when finding the best path. The default value is 0.5. -
useHills
public float useHillsA rider's desire to tackle hills in their routes. This is a range of values from 0 to 1, where 0 attempts to avoid hills and steep grades even if it means a longer (time and distance) path, while 1 indicates the rider does not fear hills and steeper grades. Based on the use_hills factor, penalties are applied to roads based on elevation change and grade. These penalties help the path avoid hilly roads in favor of flatter roads or less steep grades where available. Note that it is not always possible to find alternate paths to avoid hills (for example when route locations are in mountainous areas). The default value is 0.5. -
shortest
public boolean shortestChanges the metric to quasi-shortest, i.e. purely distance-based costing. Note, this will disable all other costings and penalties. Also note, shortest will not disable hierarchy pruning, leading to potentially sub-optimal routes for some costing models. The default is false.
-
-
Constructor Details
-
MotorScooter
public MotorScooter()
-
-
Method Details
-
write
- Throws:
IOException
-