Skip to content

Commit 28de560

Browse files
committed
Add _t suffix to class export_list
1 parent 88aa661 commit 28de560

File tree

8 files changed

+24
-23
lines changed

8 files changed

+24
-23
lines changed

src/output-pgsql.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ output_pgsql_t::output_pgsql_t(std::shared_ptr<middle_query_t> const &mid,
469469
log_debug("Using projection SRS {} ({})", options.projection->target_srs(),
470470
options.projection->target_desc());
471471

472-
export_list exlist;
472+
export_list_t exlist;
473473

474474
m_enable_way_area = read_style_file(options.style, &exlist);
475475

src/taginfo-impl.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ struct taginfo
5353
};
5454

5555
/* list of exported tags */
56-
class export_list
56+
class export_list_t
5757
{
5858
public:
5959
void add(osmium::item_type type, taginfo const &info);
@@ -76,6 +76,6 @@ unsigned parse_tag_flags(std::string const &flags, int lineno);
7676
* Returns `true` if the 'way_area' column should (implicitly) exist, or
7777
* `false` if it should be suppressed.
7878
*/
79-
bool read_style_file(std::string const &filename, export_list *exlist);
79+
bool read_style_file(std::string const &filename, export_list_t *exlist);
8080

8181
#endif // OSM2PGSQL_TAGINFO_IMPL_HPP

src/taginfo.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,18 @@
1919

2020
#include <osmium/util/string.hpp>
2121

22-
void export_list::add(osmium::item_type type, taginfo const &info)
22+
void export_list_t::add(osmium::item_type type, taginfo const &info)
2323
{
2424
m_export_list(type).push_back(info);
2525
}
2626

2727
std::vector<taginfo> const &
28-
export_list::get(osmium::item_type type) const noexcept
28+
export_list_t::get(osmium::item_type type) const noexcept
2929
{
3030
return m_export_list(type);
3131
}
3232

33-
columns_t export_list::normal_columns(osmium::item_type type) const
33+
columns_t export_list_t::normal_columns(osmium::item_type type) const
3434
{
3535
columns_t columns;
3636

@@ -89,7 +89,7 @@ unsigned get_tag_type(std::string const &tag)
8989

9090
// NOLINTBEGIN(cppcoreguidelines-avoid-c-arrays,hicpp-avoid-c-arrays,modernize-avoid-c-arrays)
9191
// This is legacy code which will be removed anyway.
92-
bool read_style_file(std::string const &filename, export_list *exlist)
92+
bool read_style_file(std::string const &filename, export_list_t *exlist)
9393
{
9494
bool enable_way_area = true;
9595

src/tagtransform-c.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@ bool starts_with(char const *input, std::string const &test) noexcept
9696

9797
} // anonymous namespace
9898

99-
c_tagtransform_t::c_tagtransform_t(options_t const *options, export_list exlist)
99+
c_tagtransform_t::c_tagtransform_t(options_t const *options,
100+
export_list_t exlist)
100101
: m_options(options), m_export_list(std::move(exlist))
101102
{}
102103

src/tagtransform-c.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
class c_tagtransform_t : public tagtransform_t
1717
{
1818
public:
19-
c_tagtransform_t(options_t const *options, export_list exlist);
19+
c_tagtransform_t(options_t const *options, export_list_t exlist);
2020

2121
std::unique_ptr<tagtransform_t> clone() const override;
2222

@@ -34,7 +34,7 @@ class c_tagtransform_t : public tagtransform_t
3434
bool *filter, unsigned int *flags);
3535

3636
options_t const *m_options;
37-
export_list m_export_list;
37+
export_list_t m_export_list;
3838
};
3939

4040
#endif // OSM2PGSQL_TAGTRANSFORM_C_HPP

src/tagtransform.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
std::unique_ptr<tagtransform_t>
2121
tagtransform_t::make_tagtransform(options_t const *options,
22-
export_list const &exlist)
22+
export_list_t const &exlist)
2323
{
2424
if (!options->tag_transform_script.empty()) {
2525
log_debug("Using lua based tag transformations with script {}",

src/tagtransform.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@
1616

1717
#include "osmtypes.hpp"
1818

19-
class export_list;
19+
class export_list_t;
2020
struct options_t;
2121

2222
class tagtransform_t
2323
{
2424
public:
2525
static std::unique_ptr<tagtransform_t>
26-
make_tagtransform(options_t const *options, export_list const &exlist);
26+
make_tagtransform(options_t const *options, export_list_t const &exlist);
2727

2828
tagtransform_t() noexcept = default;
2929

tests/test-output-pgsql-style-file.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
TEST_CASE("Parse default style file")
1616
{
17-
export_list exlist;
17+
export_list_t exlist;
1818
auto const enable_way_area =
1919
read_style_file(OSM2PGSQLDATA_DIR "default.style", &exlist);
2020

@@ -26,7 +26,7 @@ TEST_CASE("Parse default style file")
2626

2727
TEST_CASE("Parse empty style file")
2828
{
29-
export_list exlist;
29+
export_list_t exlist;
3030

3131
REQUIRE_THROWS_WITH(
3232
read_style_file(OSM2PGSQLDATA_DIR "tests/style/empty.style", &exlist),
@@ -35,15 +35,15 @@ TEST_CASE("Parse empty style file")
3535

3636
TEST_CASE("Parse style file with invalid osm type")
3737
{
38-
export_list exlist;
38+
export_list_t exlist;
3939

4040
REQUIRE_THROWS(read_style_file(
4141
OSM2PGSQLDATA_DIR "tests/style/invalid-osm-type.style", &exlist));
4242
}
4343

4444
TEST_CASE("Parse style file with comments only")
4545
{
46-
export_list exlist;
46+
export_list_t exlist;
4747

4848
REQUIRE_THROWS_WITH(
4949
read_style_file(OSM2PGSQLDATA_DIR "tests/style/comments.style",
@@ -53,7 +53,7 @@ TEST_CASE("Parse style file with comments only")
5353

5454
TEST_CASE("Parse style file with single node entry")
5555
{
56-
export_list exlist;
56+
export_list_t exlist;
5757
auto const enable_way_area =
5858
read_style_file(OSM2PGSQLDATA_DIR "tests/style/node.style", &exlist);
5959

@@ -71,7 +71,7 @@ TEST_CASE("Parse style file with single node entry")
7171

7272
TEST_CASE("Parse style file with a few valid entries")
7373
{
74-
export_list exlist;
74+
export_list_t exlist;
7575
auto const enable_way_area =
7676
read_style_file(OSM2PGSQLDATA_DIR "tests/style/valid.style", &exlist);
7777

@@ -109,7 +109,7 @@ TEST_CASE("Parse style file with a few valid entries")
109109

110110
TEST_CASE("Parse style file with missing fields")
111111
{
112-
export_list exlist;
112+
export_list_t exlist;
113113
auto const enable_way_area =
114114
read_style_file(OSM2PGSQLDATA_DIR "tests/style/missing.style", &exlist);
115115

@@ -138,7 +138,7 @@ TEST_CASE("Parse style file with missing fields")
138138

139139
TEST_CASE("Parse style file with way_area")
140140
{
141-
export_list exlist;
141+
export_list_t exlist;
142142
auto const enable_way_area = read_style_file(
143143
OSM2PGSQLDATA_DIR "tests/style/way-area.style", &exlist);
144144

@@ -168,7 +168,7 @@ TEST_CASE("Parse style file with way_area")
168168

169169
TEST_CASE("Parse style file with different data types")
170170
{
171-
export_list exlist;
171+
export_list_t exlist;
172172
auto const enable_way_area = read_style_file(
173173
OSM2PGSQLDATA_DIR "tests/style/data-types.style", &exlist);
174174

@@ -211,7 +211,7 @@ TEST_CASE("Parse style file with different data types")
211211

212212
TEST_CASE("Parse style file with invalid data types")
213213
{
214-
export_list exlist;
214+
export_list_t exlist;
215215
auto const enable_way_area = read_style_file(
216216
OSM2PGSQLDATA_DIR "tests/style/invalid-data-type.style", &exlist);
217217

0 commit comments

Comments
 (0)