source: josm/trunk/data/validator/relation.mapcss@ 15413

Last change on this file since 15413 was 14124, checked in by Klumbumbus, 6 years ago

fix #16242, see #15208 - warn about bicycle=no ways being part of bicycle route relations

  • Property svn:eol-style set to native
File size: 1.8 KB
RevLine 
[6537]1/* relation types */
2
3relation[!type] {
4 throwError: tr("relation without type");
5 assertMatch: "relation name=Foo";
6 assertNoMatch: "relation type=route name=Foo";
7}
8
9/* from http://wiki.openstreetmap.org/wiki/Types_of_relation */
[6538]10/* see also #9071 */
11relation[type=route][!route],
12relation[type=route_master][!route_master],
[8523]13relation[type=restriction][!/^restriction/], /* see #11586 */
[6538]14relation[type=boundary][!boundary],
15relation[type=public_transport][!public_transport],
16relation[type=waterway][!waterway],
17relation[type=enforcement][!enforcement] {
18 throwWarning: tr("{0} relation without {0} tag", "{1.key}");
[11146]19 group: tr("missing tag");
[6537]20 assertMatch: "relation type=route";
21 assertNoMatch: "relation type=route route=train";
22 assertMatch: "relation type=route_master";
23 assertNoMatch: "relation type=route_master route_master=train";
24 assertMatch: "relation type=restriction";
25 assertNoMatch: "relation type=restriction restriction=no_left_turn";
26 assertMatch: "relation type=boundary";
27 assertNoMatch: "relation type=boundary boundary=administrative";
28 assertNoMatch: "relation type=site site=administrative";
29 assertMatch: "relation type=public_transport";
30 assertNoMatch: "relation type=public_transport public_transport=stop_area";
31 assertMatch: "relation type=waterway";
32 assertNoMatch: "relation type=waterway waterway=river";
33 assertMatch: "relation type=enforcement";
34 assertNoMatch: "relation type=enforcement enforcement=maxspeed";
35}
[12773]36
[14124]37/* #15208, #16242 */
38relation[type=route][route=mtb ] > way[bicycle=no],
39relation[type=route][route=bicycle] > way[bicycle=no],
[12773]40relation[type=route][route=mtb ] > way[bicycle=use_sidepath],
41relation[type=route][route=bicycle] > way[bicycle=use_sidepath] {
42 throwWarning: tr("way with {0} is part of a bicycle route relation", "{0.tag}");
43}
Note: See TracBrowser for help on using the repository browser.