Overpass API regression suite coverage (Saxony) / overpass_api/output_formats/output_custom.cc

overpass_api/output_formats/output_custom.cc

13 of 515 instrumented lines run by the suite (2.5%) at 8edf11b0419c (this file on GitHub).

runnever runcolumns: line, executions, queries (click for the queries that run the line)

1/** Copyright 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018 Roland Olbricht et al.
2 *
3 * This file is part of Overpass_API.
4 *
5 * Overpass_API is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU Affero General Public License as
7 * published by the Free Software Foundation, either version 3 of the
8 * License, or (at your option) any later version.
9 *
10 * Overpass_API is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU Affero General Public License
16 * along with Overpass_API. If not, see <http://www.gnu.org/licenses/>.
17 */
19#include "../../expat/escape_xml.h"
20#include "../frontend/basic_formats.h"
21#include "output_custom.h"
23#include <cmath>
24#include <fstream>
27bool Output_Custom::write_http_headers()
280{
290 return false;
300}
33void Output_Custom::write_payload_header
34 (const std::string& db_dir_, const std::string& timestamp_, const std::string& area_timestamp_)
3611 q db_dir = db_dir_;
3711 q timestamp = timestamp_;
3811 q area_timestamp = area_timestamp_;
42std::string process_template(const std::string& raw_template, unsigned int count)
430{
440 std::ostringstream result;
450 std::string::size_type old_pos = 0;
460 std::string::size_type new_pos = 0;
480 new_pos = raw_template.find("{{{", old_pos);
490 while (new_pos != std::string::npos)
500 {
510 result<<raw_template.substr(old_pos, new_pos - old_pos);
530 if (raw_template.substr(new_pos + 3, 8) == "count}}}")
540 {
550 result<<count;
560 old_pos = new_pos + 11;
570 }
580 else
590 {
600 result<<"{{{";
610 old_pos = new_pos + 3;
620 }
630 new_pos = raw_template.find("{{{", old_pos);
640 }
650 result<<raw_template.substr(old_pos);
670 return result.str();
680}
71void Output_Custom::display_remark(const std::string& text)
720{
73 //TODO
740}
77void Output_Custom::display_error(const std::string& text)
780{
79 //TODO
800}
83std::string::size_type find_block_end(std::string data, std::string::size_type pos)
840{
850 if (pos == std::string::npos || data.substr(pos, 2) != "{{")
860 return pos;
880 std::string::size_type curly_brace_count = 2;
890 if (data.substr(pos, 3) == "{{{")
900 curly_brace_count = 3;
910 pos += curly_brace_count;
930 while (pos < data.size())
940 {
950 if (data[pos] == '{' && data.substr(pos, 2) == "{{")
960 pos = find_block_end(data, pos);
970 else if ((data[pos] == '}') && curly_brace_count == 2 && data.substr(pos, 2) == "}}")
980 return pos+2;
990 else if ((data[pos] == '}') && curly_brace_count == 3 && data.substr(pos, 3) == "}}}")
1000 return pos+3;
1010 else
1020 ++pos;
1030 }
1050 return std::string::npos;
1060}
109void Output_Custom::set_output_templates()
1100{
1110 std::string data;
1130 std::ifstream in((db_dir + "/templates/" + template_name).c_str());
1140 while (in.good())
1150 {
1160 std::string buf;
1170 std::getline(in, buf);
1180 data += buf + '\n';
1190 }
1210 if (data.find("<includeonly>") != std::string::npos)
1220 {
1230 std::string::size_type start = data.find("<includeonly>") + 13;
1240 std::string::size_type end = data.find("</includeonly>");
1250 data = data.substr(start, end - start);
1260 }
1280 template_contains_js = (data.find("<script") != std::string::npos);
1300 if (data == "")
1310 data = "\n<p>Template not found.</p>\n";
1330 node_template = "\n<p>No {{node:..}} found in template.</p>\n";
1340 way_template = "\n<p>No {{way:..}} found in template.</p>\n";
1350 relation_template = "\n<p>No {{relation:..}} found in template.</p>\n";
1370 bool header_written = false;
1380 std::string::size_type pos = 0;
1390 while (pos < data.size())
1400 {
1410 if (data[pos] == '{')
1420 {
1430 if (data.substr(pos, 7) == "{{node:")
1440 {
1450 std::string::size_type end_pos = find_block_end(data, pos);
1470 if (!header_written)
1480 {
1490 header = data.substr(0, pos);
1500 header_written = true;
1510 }
1530 if (end_pos != std::string::npos)
1540 {
1550 node_template = data.substr(pos + 7, end_pos - pos - 9);
1560 pos = end_pos;
1570 }
1580 else
1590 pos = data.size();
1600 }
1610 else if (data.substr(pos, 6) == "{{way:")
1620 {
1630 std::string::size_type end_pos = find_block_end(data, pos);
1650 if (!header_written)
1660 {
1670 header = data.substr(0, pos);
1680 header_written = true;
1690 }
1710 if (end_pos != std::string::npos)
1720 {
1730 way_template = data.substr(pos + 6, end_pos - pos - 8);
1740 pos = end_pos;
1750 }
1760 else
1770 pos = data.size();
1780 }
1790 else if (data.substr(pos, 11) == "{{relation:")
1800 {
1810 std::string::size_type end_pos = find_block_end(data, pos);
1830 if (!header_written)
1840 {
1850 header = data.substr(0, pos);
1860 header_written = true;
1870 }
1890 if (end_pos != std::string::npos)
1900 {
1910 relation_template = data.substr(pos + 11, end_pos - pos - 13);
1920 pos = end_pos;
1930 }
1940 else
1950 pos = data.size();
1960 }
1970 else
1980 ++pos;
1990 }
2000 else
2010 ++pos;
2020 }
2040 if (!header_written)
2050 header = data.substr(0, pos);
2060}
209std::string process_members(const std::string& raw_template, Node::Id_Type ref)
2100{
2110 std::ostringstream result;
2120 std::string::size_type old_pos = 0;
2130 std::string::size_type new_pos = 0;
2150 new_pos = raw_template.find("{{", old_pos);
2160 while (new_pos != std::string::npos)
2170 {
2180 result<<raw_template.substr(old_pos, new_pos - old_pos);
2190 old_pos = find_block_end(raw_template, new_pos);
2200 if (old_pos == std::string::npos)
2210 {
2220 result<<raw_template.substr(new_pos);
2230 return result.str();
2240 }
2250 else if (raw_template.substr(new_pos, 9) == "{{{ref}}}")
2260 result<<ref.val();
2270 else if (raw_template.substr(new_pos, 8) == "{{first:")
2280 ;
2290 else
2300 result<<raw_template.substr(new_pos, old_pos - new_pos);
2310 new_pos = raw_template.find("{{", old_pos);
2320 }
2330 result<<raw_template.substr(old_pos, new_pos - old_pos);
2350 return result.str();
2360}
239std::string process_members(const std::string& raw_template, uint32 id, const Relation_Entry& entry,
240 const std::map< uint32, std::string >& roles)
2410{
2420 std::ostringstream result;
2430 std::string::size_type old_pos = 0;
2440 std::string::size_type new_pos = 0;
2460 new_pos = raw_template.find("{{", old_pos);
2470 while (new_pos != std::string::npos)
2480 {
2490 result<<raw_template.substr(old_pos, new_pos - old_pos);
2500 old_pos = find_block_end(raw_template, new_pos);
2510 if (old_pos == std::string::npos)
2520 {
2530 result<<raw_template.substr(new_pos);
2540 return result.str();
2550 }
2560 else if (raw_template.substr(new_pos, 8) == "{{{id}}}")
2570 result<<id;
2580 else if (raw_template.substr(new_pos, 9) == "{{{ref}}}")
2590 result<<entry.ref.val();
2600 else if (raw_template.substr(new_pos, 10) == "{{{type}}}")
2610 result<<member_type_name(entry.type);
2620 else if (raw_template.substr(new_pos, 10) == "{{{role}}}")
2630 {
2640 std::map< uint32, std::string >::const_iterator rit = roles.find(entry.role);
2650 result<<escape_xml(rit != roles.end() ? rit->second : "???");
2660 }
2670 else if (raw_template.substr(new_pos, 8) == "{{first:")
2680 ;
2690 else
2700 result<<raw_template.substr(new_pos, old_pos - new_pos);
2710 new_pos = raw_template.find("{{", old_pos);
2720 }
2730 result<<raw_template.substr(old_pos, new_pos - old_pos);
2750 return result.str();
2760}
279std::string process_tags(const std::string& raw_template, uint32 id, const std::string& key, const std::string& value)
2800{
2810 std::ostringstream result;
2820 std::string::size_type old_pos = 0;
2830 std::string::size_type new_pos = 0;
2850 new_pos = raw_template.find("{{", old_pos);
2860 while (new_pos != std::string::npos)
2870 {
2880 result<<raw_template.substr(old_pos, new_pos - old_pos);
2890 old_pos = find_block_end(raw_template, new_pos);
2900 if (old_pos == std::string::npos)
2910 {
2920 result<<raw_template.substr(new_pos);
2930 return result.str();
2940 }
2950 else if (raw_template.substr(new_pos, 8) == "{{{id}}}")
2960 result<<id;
2970 else if (raw_template.substr(new_pos, 9) == "{{{key}}}")
2980 result<<key;
2990 else if (raw_template.substr(new_pos, 11) == "{{{value}}}")
3000 result<<value;
3010 else if (raw_template.substr(new_pos, 8) == "{{first:")
3020 ;
3030 else
3040 result<<raw_template.substr(new_pos, old_pos - new_pos);
3050 new_pos = raw_template.find("{{", old_pos);
3060 }
3070 result<<raw_template.substr(old_pos, new_pos - old_pos);
3090 return result.str();
3100}
313std::string process_coords(const std::string& raw_template, uint32 id, double lat, double lon)
3140{
3150 std::ostringstream result;
3160 std::string::size_type old_pos = 0;
3170 std::string::size_type new_pos = 0;
3190 new_pos = raw_template.find("{{", old_pos);
3200 while (new_pos != std::string::npos)
3210 {
3220 result<<raw_template.substr(old_pos, new_pos - old_pos);
3230 old_pos = find_block_end(raw_template, new_pos);
3240 if (old_pos == std::string::npos)
3250 {
3260 result<<raw_template.substr(new_pos);
3270 return result.str();
3280 }
3290 else if (raw_template.substr(new_pos, 8) == "{{{id}}}")
3300 result<<id;
3310 else if (raw_template.substr(new_pos, 9) == "{{{lat}}}")
3320 result<<std::fixed<<std::setprecision(7)<<lat;
3330 else if (raw_template.substr(new_pos, 9) == "{{{lon}}}")
3340 result<<std::fixed<<std::setprecision(7)<<lon;
3350 else
3360 result<<raw_template.substr(new_pos, old_pos - new_pos);
3370 new_pos = raw_template.find("{{", old_pos);
3380 }
3390 result<<raw_template.substr(old_pos, new_pos - old_pos);
3410 return result.str();
3420}
345std::string process_coords(const std::string& raw_template, uint32 id,
346 double south, double west, double north, double east, uint zoom)
3470{
3480 std::ostringstream result;
3490 std::string::size_type old_pos = 0;
3500 std::string::size_type new_pos = 0;
3520 new_pos = raw_template.find("{{", old_pos);
3530 while (new_pos != std::string::npos)
3540 {
3550 result<<raw_template.substr(old_pos, new_pos - old_pos);
3560 old_pos = find_block_end(raw_template, new_pos);
3570 if (old_pos == std::string::npos)
3580 {
3590 result<<raw_template.substr(new_pos);
3600 return result.str();
3610 }
3620 else if (raw_template.substr(new_pos, 8) == "{{{id}}}")
3630 result<<id;
3640 else if (raw_template.substr(new_pos, 11) == "{{{south}}}")
3650 result<<std::fixed<<std::setprecision(7)<<south;
3660 else if (raw_template.substr(new_pos, 10) == "{{{west}}}")
3670 result<<std::fixed<<std::setprecision(7)<<west;
3680 else if (raw_template.substr(new_pos, 11) == "{{{north}}}")
3690 result<<std::fixed<<std::setprecision(7)<<north;
3700 else if (raw_template.substr(new_pos, 10) == "{{{east}}}")
3710 result<<std::fixed<<std::setprecision(7)<<east;
3720 else if (raw_template.substr(new_pos, 9) == "{{{lat}}}")
3730 result<<std::fixed<<std::setprecision(7)<<(south + north)/2.0;
3740 else if (raw_template.substr(new_pos, 9) == "{{{lon}}}")
3750 result<<std::fixed<<std::setprecision(7)<<(east + west)/2.0;
3760 else if (raw_template.substr(new_pos, 10) == "{{{zoom}}}")
3770 result<<zoom;
3780 else if (raw_template.substr(new_pos, 7) == "{{none:")
3790 ;
3800 else
3810 result<<raw_template.substr(new_pos, old_pos - new_pos);
3820 new_pos = raw_template.find("{{", old_pos);
3830 }
3840 result<<raw_template.substr(old_pos, new_pos - old_pos);
3860 return result.str();
3870}
390std::string extract_first(const std::string& raw_template)
3910{
3920 std::string::size_type old_pos = 0;
3930 std::string::size_type new_pos = 0;
3950 new_pos = raw_template.find("{{", old_pos);
3960 while (new_pos != std::string::npos)
3970 {
3980 old_pos = find_block_end(raw_template, new_pos);
3990 if (old_pos == std::string::npos)
4000 return "";
4010 else if (raw_template.substr(new_pos, 8) == "{{first:")
4020 return raw_template.substr(new_pos + 8, old_pos - new_pos - 10);
4030 new_pos = raw_template.find("{{", old_pos);
4040 }
4060 return "";
4070}
410std::string antiprocess_coords(const std::string& raw_template)
4110{
4120 std::ostringstream result;
4130 std::string::size_type old_pos = 0;
4140 std::string::size_type new_pos = 0;
4160 new_pos = raw_template.find("{{", old_pos);
4170 while (new_pos != std::string::npos)
4180 {
4190 result<<raw_template.substr(old_pos, new_pos - old_pos);
4200 old_pos = find_block_end(raw_template, new_pos);
4210 if (old_pos == std::string::npos)
4220 {
4230 result<<raw_template.substr(new_pos);
4240 return result.str();
4250 }
4260 else if (raw_template.substr(new_pos, 7) == "{{none:")
4270 return raw_template.substr(new_pos + 7, old_pos - new_pos - 9);
4280 else
4290 result<<raw_template.substr(new_pos, old_pos - new_pos);
4300 new_pos = raw_template.find("{{", old_pos);
4310 }
4320 result<<raw_template.substr(old_pos, new_pos - old_pos);
4340 return result.str();
4350}
438std::string process_template(const std::string& raw_template, unsigned long long id, std::string type,
439 double south, double west, double north, double east, uint zoom,
440 const std::vector< std::pair< std::string, std::string > >* tags,
441 const std::vector< Node::Id_Type >* nds,
442 const std::vector< Relation_Entry >* members,
443 const std::map< uint32, std::string >* roles)
4440{
4450 std::ostringstream result;
4460 std::string::size_type old_pos = 0;
4470 std::string::size_type new_pos = 0;
4490 new_pos = raw_template.find("{{", old_pos);
4500 while (new_pos != std::string::npos)
4510 {
4520 result<<raw_template.substr(old_pos, new_pos - old_pos);
4530 old_pos = find_block_end(raw_template, new_pos);
4540 if (old_pos == std::string::npos)
4550 {
4560 result<<raw_template.substr(new_pos);
4570 return result.str();
4580 }
4590 else if (raw_template.substr(new_pos, 8) == "{{{id}}}")
4600 result<<id;
4610 else if (raw_template.substr(new_pos, 10) == "{{{type}}}")
4620 result<<type;
4630 else if (raw_template.substr(new_pos, 9) == "{{coords:")
4640 {
4650 if (south < 100.0)
4660 result<<process_coords(raw_template.substr(new_pos + 9, old_pos - new_pos - 11), id,
4670 south, west);
4680 }
4690 else if (raw_template.substr(new_pos, 7) == "{{bbox:")
4700 {
4710 if (south < 100.0 && north < 100.0)
4720 result<<process_coords(raw_template.substr(new_pos + 7, old_pos - new_pos - 9), id,
4730 south, west, north, east, zoom);
4740 else if (south == 200.0)
4750 result<<antiprocess_coords(raw_template.substr(new_pos + 7, old_pos - new_pos - 9));
4760 }
4770 else if (raw_template.substr(new_pos, 7) == "{{tags:")
4780 {
4790 if (tags != 0 && !tags->empty())
4800 {
4810 std::vector< std::pair< std::string, std::string > >::const_iterator it = tags->begin();
4830 std::string first = extract_first(raw_template.substr(new_pos + 7, old_pos - new_pos - 9));
4840 if (first != "" && it != tags->end())
4850 {
4860 result<<process_tags(first, id, escape_xml(it->first), escape_xml(it->second));
4870 ++it;
4880 }
4900 for (; it != tags->end(); ++it)
4910 result<<process_tags(raw_template.substr(new_pos + 7, old_pos - new_pos - 9), id,
4920 escape_xml(it->first), escape_xml(it->second));
4930 }
4940 }
4950 else if (raw_template.substr(new_pos, 10) == "{{members:")
4960 {
4970 if (nds != 0 && !nds->empty())
4980 {
4990 std::vector< Node::Id_Type >::const_iterator it = nds->begin();
5010 std::string first = extract_first(raw_template.substr(new_pos + 10, old_pos - new_pos - 12));
5020 if (first != "" && it != nds->end())
5030 {
5040 result<<process_members(first, *it);
5050 ++it;
5060 }
5080 for (; it != nds->end(); ++it)
5090 result<<process_members(raw_template.substr(new_pos + 10, old_pos - new_pos - 12), *it);
5100 }
5110 else if (members != 0 && !members->empty())
5120 {
5130 std::vector< Relation_Entry >::const_iterator it = members->begin();
5150 std::string first = extract_first(raw_template.substr(new_pos + 10, old_pos - new_pos - 12));
5160 if (first != "" && it != members->end())
5170 {
5180 result<<process_members(first, id, *it, *roles);
5190 ++it;
5200 }
5220 for (; it != members->end(); ++it)
5230 result<<process_members(raw_template.substr(new_pos + 10, old_pos - new_pos - 12), id,
5240 *it, *roles);
5250 }
5260 }
5270 else
5280 result<<raw_template.substr(new_pos, old_pos - new_pos);
5290 new_pos = raw_template.find("{{", old_pos);
5300 }
5310 result<<raw_template.substr(old_pos);
5330 return result.str();
5340}
537void Output_Custom::write_footer()
53911 q if (count == 0 && redirect)
54111 q ::write_html_header(timestamp, area_timestamp, 200, false, true);
54211 q std::cout<<"<p>No results found.</p>\n";
54311 q std::cout<<"\n</body>\n</html>\n";
5450 else if (count == 1 && redirect)
5460 {
5470 std::cout<<"Status: 302 Moved\n";
5480 std::cout<<"Location: "
5490 <<process_template(url, first_id, first_type, 100.0, 200.0, 0, 17, 0, 0, 0, 0, 0)<<"\n\n";
5500 }
5510 else
5520 {
5530 ::write_html_header(timestamp, area_timestamp, 200, template_contains_js, true);
5540 std::cout<<process_template(header, count);
5550 std::cout<<'\n';
5560 std::cout<<output;
5570 std::cout<<"\n</body>\n</html>\n";
5580 }
562void Output_Custom::print_item(const Node_Skeleton& skel,
563 const Opaque_Geometry& geometry,
564 const std::vector< std::pair< std::string, std::string > >* tags,
565 const OSM_Element_Metadata_Skeleton< Node::Id_Type >* meta,
566 const std::map< uint32, std::string >* users,
567 Output_Mode mode,
568 const Feature_Action& action,
569 const Node_Skeleton* new_skel,
570 const Opaque_Geometry* new_geometry,
571 const std::vector< std::pair< std::string, std::string > >* new_tags,
572 const OSM_Element_Metadata_Skeleton< Node::Id_Type >* new_meta)
5730{
5740 if (count == 0)
5750 {
5760 set_output_templates();
5780 first_type = "node";
5790 first_id = skel.id.val();
5800 }
5810 ++count;
5830 double lat = 100.0;
5840 double lon = 200.0;
5850 if (mode.mode & (Output_Mode::COORDS | Output_Mode::GEOMETRY | Output_Mode::BOUNDS | Output_Mode::CENTER))
5860 {
5870 lat = geometry.center_lat();
5880 lon = geometry.center_lon();
5890 }
5900 output += process_template(node_template, skel.id.val(), "node", lat, lon, 100.0, 0, 17, tags, 0, 0, 0);
5910}
594// struct Box_Coords
595// {
596// Box_Coords() : south(100.0), west(200.0), north(0), east(0) {}
597//
598// Box_Coords(Uint31_Index ll_upper)
599// {
600// pair< Uint32_Index, Uint32_Index > bbox_bounds = calc_bbox_bounds(ll_upper);
601// if (bbox_bounds.second.val() == 1)
602// {
603// south = 200.0;
604// west = 200.0;
605// north = 0;
606// east = 0;
607// }
608// else
609// {
610// south = ::lat(bbox_bounds.first.val(), 0);
611// west = ::lon(bbox_bounds.first.val(), 0);
612// north = ::lat(bbox_bounds.second.val() - 1, 0xffffffffu);
613// east = ::lon(bbox_bounds.second.val() - 1, 0xffffffffu);
614// }
615// }
616//
617// double south, west, north, east;
618// };
621unsigned int detect_zoom(const Opaque_Geometry& geometry)
6220{
6230 if (!geometry.has_bbox())
6240 return 16;
6260 double delta_lat = geometry.north() - geometry.south();
6270 double delta_lon = fabs(geometry.west() - geometry.east());
6290 double threshold = 0.012;
6300 unsigned int result = 15;
6310 while (delta_lat > threshold || delta_lon > threshold)
6320 {
6330 threshold *= 2;
6340 --result;
6350 }
6360 return result;
6370}
640void Output_Custom::print_item(const Way_Skeleton& skel,
641 const Opaque_Geometry& geometry,
642 const std::vector< std::pair< std::string, std::string > >* tags,
643 const OSM_Element_Metadata_Skeleton< Way::Id_Type >* meta,
644 const std::map< uint32, std::string >* users,
645 Output_Mode mode,
646 const Feature_Action& action,
647 const Way_Skeleton* new_skel,
648 const Opaque_Geometry* new_geometry,
649 const std::vector< std::pair< std::string, std::string > >* new_tags,
650 const OSM_Element_Metadata_Skeleton< Way::Id_Type >* new_meta)
6510{
6520 if (count == 0)
6530 {
6540 set_output_templates();
6560 first_type = "way";
6570 first_id = skel.id.val();
6580 }
6590 ++count;
6610 if (geometry.has_bbox())
6620 {
6630 output += process_template(way_template, skel.id.val(), "way",
6640 geometry.south(), geometry.west(), geometry.north(), geometry.east(),
6650 detect_zoom(geometry),
6660 tags, mode.mode & Output_Mode::NDS ? &skel.nds : 0, 0, 0);
6670 }
6680 else
6690 {
6700 output += process_template(way_template, skel.id.val(), "way",
6710 200.0, 200.0, 200.0, 200.0,
6720 detect_zoom(geometry),
6730 tags, mode.mode & Output_Mode::NDS ? &skel.nds : 0, 0, 0);
6740 }
6750}
678void Output_Custom::print_item(const Relation_Skeleton& skel,
679 const Opaque_Geometry& geometry,
680 const std::vector< std::pair< std::string, std::string > >* tags,
681 const OSM_Element_Metadata_Skeleton< Relation::Id_Type >* meta,
682 const std::map< uint32, std::string >* roles,
683 const std::map< uint32, std::string >* users,
684 Output_Mode mode,
685 const Feature_Action& action,
686 const Relation_Skeleton* new_skel,
687 const Opaque_Geometry* new_geometry,
688 const std::vector< std::pair< std::string, std::string > >* new_tags,
689 const OSM_Element_Metadata_Skeleton< Relation::Id_Type >* new_meta)
6900{
6910 if (count == 0)
6920 {
6930 set_output_templates();
6950 first_type = "relation";
6960 first_id = skel.id.val();
6970 }
6980 ++count;
7000 if (geometry.has_bbox())
7010 {
7020 output += process_template(relation_template, skel.id.val(), "relation",
7030 geometry.south(), geometry.west(), geometry.north(), geometry.east(),
7040 detect_zoom(geometry),
7050 tags, 0, mode.mode & Output_Mode::MEMBERS ? &skel.members : 0, roles);
7060 }
7070 else
7080 {
7090 output += process_template(relation_template, skel.id.val(), "relation",
7100 200.0, 200.0, 200.0, 200.0,
7110 detect_zoom(geometry),
7120 tags, 0, mode.mode & Output_Mode::MEMBERS ? &skel.members : 0, roles);
7130 }
7140}
717void Output_Custom::print_item(const Derived_Skeleton& skel,
718 const Opaque_Geometry& geometry,
719 const std::vector< std::pair< std::string, std::string > >* tags,
720 Output_Mode mode,
721 const Feature_Action& action)
7220{
723 // Intentionally empty
7240}