Skip to content

Commit

Permalink
Expose ignore_access and ignore_restrictions API flags (#217)
Browse files Browse the repository at this point in the history
  • Loading branch information
eikes authored Apr 26, 2024
1 parent 2661dc6 commit 98de6b6
Showing 1 changed file with 36 additions and 3 deletions.
39 changes: 36 additions & 3 deletions src/Controls/settings-options.js
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,20 @@ const ignoreClosures = {
param: 'ignore_closures',
}

const ignoreRestrictions = {
name: 'Ignore Restrictions',
description:
'If set to true, ignores any restrictions (e.g. turn/dimensional/conditional restrictions). Especially useful for matching GPS traces to the road network regardless of restrictions.',
param: 'ignore_restrictions',
}

const ignoreAccess = {
name: 'Ignore Access',
description:
'If set to true, Will ignore mode-specific access tags. Especially useful for matching GPS traces to the road network regardless of restrictions.',
param: 'ignore_access',
}

const closureFactor = {
name: 'Closure Factor',
param: 'closure_factor',
Expand Down Expand Up @@ -690,6 +704,8 @@ export const settingsInit = {
use_tracks: 0,
private_access_penalty: 450,
ignore_closures: false,
ignore_restrictions: false,
ignore_access: false,
closure_factor: 9,
service_penalty: 15,
service_factor: 1,
Expand Down Expand Up @@ -900,6 +916,8 @@ export const settings_general = {
],
boolean: [
ignoreClosures,
ignoreRestrictions,
ignoreAccess,
excludeCashOnlyTolls,
includeHOV3,
includeHOV2,
Expand All @@ -922,7 +940,12 @@ export const settings_general = {
useTracks,
excludeUnpaved,
],
boolean: [ignoreClosures, excludeCashOnlyTolls],
boolean: [
ignoreClosures,
ignoreRestrictions,
ignoreAccess,
excludeCashOnlyTolls,
],
enum: [],
},
bus: {
Expand All @@ -940,7 +963,12 @@ export const settings_general = {
useTracks,
excludeUnpaved,
],
boolean: [ignoreClosures, excludeCashOnlyTolls],
boolean: [
ignoreClosures,
ignoreRestrictions,
ignoreAccess,
excludeCashOnlyTolls,
],
enum: [],
},
pedestrian: {
Expand Down Expand Up @@ -990,7 +1018,12 @@ export const settings_general = {
useTracks,
excludeUnpaved,
],
boolean: [ignoreClosures, excludeCashOnlyTolls],
boolean: [
ignoreClosures,
ignoreRestrictions,
ignoreAccess,
excludeCashOnlyTolls,
],
enum: [],
},
all: {
Expand Down

0 comments on commit 98de6b6

Please sign in to comment.