Creating an indoor route-type service
Building a route based on a specified type value, such as a Barrier Free Route or Standard Pedestrian Route value, is great for your users. How to build different route types is based on the available data connected to our indoor graph of ways. This example will allow a user to select the barrier-free route and our service will generate a path, avoiding obstacles such as stairs:
Getting ready
We need to access some more data on our network to allow routing types. The type of route is based on a network line type, which is stored as an attribute on each LineString. To classify our route types, we have the following lookup table schema:
Value |
Route type |
---|---|
|
Indoor route |
|
Outdoor route |
|
Elevator |
|
Stairs |
Therefore, we want to avoid any stairs segments, which technically means avoiding type_id = 3
.
Note
Optionally, you could create a lookup table to store all the possible types and their equivalent weights. These values could then be included...