diff options
author | mvglasow <michael -at- vonglasow.com> | 2015-12-15 19:20:06 +0100 |
---|---|---|
committer | mvglasow <michael -at- vonglasow.com> | 2015-12-15 19:20:06 +0100 |
commit | dcd62808da3c360d3549be1426e00b540ed955dc (patch) | |
tree | bd27eea61dd7bae8e34d144d08d72ff55c323761 /navit/vehicleprofile.h | |
parent | b61fded36b6e11027e18b7042b078285dc7a656f (diff) | |
download | navit-dcd62808da3c360d3549be1426e00b540ed955dc.tar.gz |
Refactor:core:Use constants for vehicleprofile.maxspeed_handlingR6419
Signed-off-by: mvglasow <michael -at- vonglasow.com>
Diffstat (limited to 'navit/vehicleprofile.h')
-rw-r--r-- | navit/vehicleprofile.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/navit/vehicleprofile.h b/navit/vehicleprofile.h index 67d3f4fa1..4e1b6a340 100644 --- a/navit/vehicleprofile.h +++ b/navit/vehicleprofile.h @@ -21,13 +21,22 @@ #ifdef __cplusplus extern "C" { #endif + + +enum maxspeed_handling { + maxspeed_enforce = 0, /*!< Always enforce maxspeed of segment */ + maxspeed_restrict = 1, /*!< Enforce maxspeed of segment only if it restricts the speed */ + maxspeed_ignore = 2, /*!< Ignore maxspeed of segment, always use {@code route_weight} of road profile */ +}; + + struct vehicleprofile { NAVIT_OBJECT int mode; /**< 0 = Auto, 1 = On-Road, 2 = Off-Road */ int flags_forward_mask; /**< Flags mask for moving in positive direction */ int flags_reverse_mask; /**< Flags mask for moving in reverse direction */ int flags; /**< Required flags to move through a segment */ - int maxspeed_handling; /**< 0 = Always, 1 = Only if lower, 2 = Never */ + int maxspeed_handling; /**< How to handle maxspeed of segment, see {@code enum maxspeed_handling} */ int static_speed; /**< Maximum speed of vehicle to consider it stationary */ int static_distance; /**< Maximum distance of previous position of vehicle to consider it stationary */ char *name; /**< the vehicle profile name */ |