mirror of
https://github.com/cfpwastaken/planetiler-openmaptiles.git
synced 2026-02-04 04:21:08 +00:00
Rename Basemap to OpenMapTiles (#1)
This commit is contained in:
22
README.md
22
README.md
@@ -1,7 +1,7 @@
|
||||
# Planetiler Basemap Profile
|
||||
# Planetiler OpenMapTiles Profile
|
||||
|
||||
This basemap profile is based on [OpenMapTiles](https://github.com/openmaptiles/openmaptiles) v3.13.
|
||||
See [README.md](../README.md) in the parent directory for instructions on how to run.
|
||||
This OpenMapTiles profile is based on [OpenMapTiles](https://github.com/openmaptiles/openmaptiles).
|
||||
See [README.md](https://github.com/onthegomap/planetiler/blob/main/README.md) in the parent repository for instructions on how to run.
|
||||
|
||||
## Differences from OpenMapTiles
|
||||
|
||||
@@ -14,30 +14,30 @@ See [README.md](../README.md) in the parent directory for instructions on how to
|
||||
|
||||
## Code Layout
|
||||
|
||||
[Generate.java](./src/main/java/com/onthegomap/planetiler/basemap/Generate.java) generates code in
|
||||
the [generated](./src/main/java/com/onthegomap/planetiler/basemap/generated) package from an OpenMapTiles tag in GitHub:
|
||||
[Generate.java](./src/main/java/com/onthegomap/planetiler/openmaptiles/Generate.java) generates code in
|
||||
the [generated](./src/main/java/com/onthegomap/planetiler/openmaptiles/generated) package from an OpenMapTiles tag in GitHub:
|
||||
|
||||
- [OpenMapTilesSchema](./src/main/java/com/onthegomap/planetiler/basemap/generated/OpenMapTilesSchema.java)
|
||||
- [OpenMapTilesSchema](./src/main/java/com/onthegomap/planetiler/openmaptiles/generated/OpenMapTilesSchema.java)
|
||||
contains an interface for each layer with constants for the name, attributes, and allowed values for each tag in that
|
||||
layer
|
||||
- [Tables](./src/main/java/com/onthegomap/planetiler/basemap/generated/Tables.java)
|
||||
- [Tables](./src/main/java/com/onthegomap/planetiler/openmaptiles/generated/Tables.java)
|
||||
contains a record for each table that OpenMapTiles [imposm3](https://github.com/omniscale/imposm3) configuration
|
||||
generates (along with the tag-filtering expression) so layers can listen on instances of those records instead of
|
||||
doing the tag filtering and parsing themselves
|
||||
|
||||
The [layers](./src/main/java/com/onthegomap/planetiler/basemap/layers) package contains a port of the SQL logic to
|
||||
The [layers](./src/main/java/com/onthegomap/planetiler/openmaptiles/layers) package contains a port of the SQL logic to
|
||||
generate each layer from OpenMapTiles. Layers define how source features (or parsed imposm3 table rows) map to vector
|
||||
tile features, and logic for post-processing tile geometries.
|
||||
|
||||
[BasemapProfile](./src/main/java/com/onthegomap/planetiler/basemap/BasemapProfile.java) dispatches source features to
|
||||
[OpenMapTilesProfile](./src/main/java/com/onthegomap/planetiler/openmaptiles/OpenMapTilesProfile.java) dispatches source features to
|
||||
layer handlers and merges the results.
|
||||
|
||||
[BasemapMain](./src/main/java/com/onthegomap/planetiler/basemap/BasemapMain.java) is the main driver that registers
|
||||
[OpenMapTilesMain](./src/main/java/com/onthegomap/planetiler/openmaptiles/OpenMapTilesMain.java) is the main driver that registers
|
||||
source data and output location.
|
||||
|
||||
## Regenerating Code
|
||||
|
||||
To run `Generate.java`, use [scripts/regenerate-openmaptiles.sh](../scripts/regenerate-openmaptiles.sh) script with the
|
||||
To run `Generate.java`, use [scripts/regenerate-openmaptiles.sh](https://github.com/onthegomap/planetiler/blob/main/scripts/regenerate-openmaptiles.sh) script with the
|
||||
OpenMapTiles release tag:
|
||||
|
||||
```bash
|
||||
|
||||
2
pom.xml
2
pom.xml
@@ -4,7 +4,7 @@
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>planetiler-basemap</artifactId>
|
||||
<artifactId>planetiler-openmaptiles</artifactId>
|
||||
|
||||
<parent>
|
||||
<groupId>com.onthegomap.planetiler</groupId>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import static com.onthegomap.planetiler.expression.Expression.*;
|
||||
import static java.util.stream.Collectors.joining;
|
||||
@@ -161,9 +161,9 @@ public class Generate {
|
||||
tables.putAll(layer.tables);
|
||||
}
|
||||
|
||||
String packageName = "com.onthegomap.planetiler.basemap.generated";
|
||||
String packageName = "com.onthegomap.planetiler.openmaptiles.generated";
|
||||
String[] packageParts = packageName.split("\\.");
|
||||
Path output = Path.of("planetiler-basemap", "src", "main", "java")
|
||||
Path output = Path.of("planetiler-openmaptiles", "src", "main", "java")
|
||||
.resolve(Path.of(packageParts[0], Arrays.copyOfRange(packageParts, 1, packageParts.length)));
|
||||
|
||||
FileUtils.deleteDirectory(output);
|
||||
@@ -188,7 +188,7 @@ public class Generate {
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.basemap.Layer;
|
||||
import com.onthegomap.planetiler.openmaptiles.Layer;
|
||||
import com.onthegomap.planetiler.util.Translations;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -225,7 +225,7 @@ public class Generate {
|
||||
info.languages.stream().map(Format::quote).collect(joining(", ")),
|
||||
layers.stream()
|
||||
.map(
|
||||
l -> "new com.onthegomap.planetiler.basemap.layers.%s(translations, config, stats)"
|
||||
l -> "new com.onthegomap.planetiler.openmaptiles.layers.%s(translations, config, stats)"
|
||||
.formatted(lowerUnderscoreToUpperCamel(l.layer.id)))
|
||||
.collect(joining("," + LINE_SEPARATOR))
|
||||
.indent(6).trim()
|
||||
@@ -1,8 +1,8 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import com.onthegomap.planetiler.ForwardingProfile;
|
||||
|
||||
/** Interface for all vector tile layer implementations that {@link BasemapProfile} delegates to. */
|
||||
/** Interface for all vector tile layer implementations that {@link OpenMapTilesProfile} delegates to. */
|
||||
public interface Layer extends
|
||||
ForwardingProfile.Handler,
|
||||
ForwardingProfile.HandlerForLayer {}
|
||||
@@ -1,14 +1,14 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import com.onthegomap.planetiler.Planetiler;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.config.Arguments;
|
||||
import java.nio.file.Path;
|
||||
|
||||
/**
|
||||
* Main entrypoint for generating a map using the basemap schema.
|
||||
* Main entrypoint for generating a map using the OpenMapTiles schema.
|
||||
*/
|
||||
public class BasemapMain {
|
||||
public class OpenMapTilesMain {
|
||||
|
||||
public static void main(String[] args) throws Exception {
|
||||
run(Arguments.fromArgsOrConfigFile(args));
|
||||
@@ -29,21 +29,21 @@ public class BasemapMain {
|
||||
.setDefaultLanguages(OpenMapTilesSchema.LANGUAGES)
|
||||
.fetchWikidataNameTranslations(sourcesDir.resolve("wikidata_names.json"))
|
||||
// defer creation of the profile because it depends on data from the runner
|
||||
.setProfile(BasemapProfile::new)
|
||||
.setProfile(OpenMapTilesProfile::new)
|
||||
// override any of these with arguments: --osm_path=... or --osm_url=...
|
||||
// or OSM_PATH=... OSM_URL=... environmental argument
|
||||
// or osm_path=... osm_url=... in a config file
|
||||
.addShapefileSource("EPSG:3857", BasemapProfile.LAKE_CENTERLINE_SOURCE,
|
||||
.addShapefileSource("EPSG:3857", OpenMapTilesProfile.LAKE_CENTERLINE_SOURCE,
|
||||
sourcesDir.resolve("lake_centerline.shp.zip"),
|
||||
// was previously using this old build from 2016: https://github.com/lukasmartinelli/osm-lakelines/releases/download/v0.9/lake_centerline.shp.zip
|
||||
"https://github.com/acalcutt/osm-lakelines/releases/download/latest/lake_centerline.shp.zip")
|
||||
.addShapefileSource(BasemapProfile.WATER_POLYGON_SOURCE,
|
||||
.addShapefileSource(OpenMapTilesProfile.WATER_POLYGON_SOURCE,
|
||||
sourcesDir.resolve("water-polygons-split-3857.zip"),
|
||||
"https://osmdata.openstreetmap.de/download/water-polygons-split-3857.zip")
|
||||
.addNaturalEarthSource(BasemapProfile.NATURAL_EARTH_SOURCE,
|
||||
.addNaturalEarthSource(OpenMapTilesProfile.NATURAL_EARTH_SOURCE,
|
||||
sourcesDir.resolve("natural_earth_vector.sqlite.zip"),
|
||||
"https://naciscdn.org/naturalearth/packages/natural_earth_vector.sqlite.zip")
|
||||
.addOsmSource(BasemapProfile.OSM_SOURCE,
|
||||
.addOsmSource(OpenMapTilesProfile.OSM_SOURCE,
|
||||
sourcesDir.resolve(area.replaceAll("[^a-zA-Z]+", "_") + ".osm.pbf"),
|
||||
"planet".equalsIgnoreCase(area) ? ("aws:latest") : ("geofabrik:" + area))
|
||||
// override with --mbtiles=... argument or MBTILES=... env var or mbtiles=... in a config file
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import static com.onthegomap.planetiler.geo.GeoUtils.EMPTY_LINE;
|
||||
import static com.onthegomap.planetiler.geo.GeoUtils.EMPTY_POINT;
|
||||
@@ -8,10 +8,10 @@ import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.ForwardingProfile;
|
||||
import com.onthegomap.planetiler.Planetiler;
|
||||
import com.onthegomap.planetiler.Profile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.layers.Transportation;
|
||||
import com.onthegomap.planetiler.basemap.layers.TransportationName;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.layers.Transportation;
|
||||
import com.onthegomap.planetiler.openmaptiles.layers.TransportationName;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.reader.SimpleFeature;
|
||||
@@ -41,7 +41,7 @@ import java.util.List;
|
||||
* {@link FinishHandler} or post-process features in that layer before rendering the output tile by implementing
|
||||
* {@link FeaturePostProcessor}.
|
||||
*/
|
||||
public class BasemapProfile extends ForwardingProfile {
|
||||
public class OpenMapTilesProfile extends ForwardingProfile {
|
||||
|
||||
// IDs used in stats and logs for each input source, as well as argument/config file overrides to source locations
|
||||
public static final String LAKE_CENTERLINE_SOURCE = "lake_centerlines";
|
||||
@@ -53,11 +53,11 @@ public class BasemapProfile extends ForwardingProfile {
|
||||
/** Index variant that filters out any table only used by layers that implement IgnoreWikidata class. */
|
||||
private final MultiExpression.Index<Boolean> wikidataMappings;
|
||||
|
||||
public BasemapProfile(Planetiler runner) {
|
||||
public OpenMapTilesProfile(Planetiler runner) {
|
||||
this(runner.translations(), runner.config(), runner.stats());
|
||||
}
|
||||
|
||||
public BasemapProfile(Translations translations, PlanetilerConfig config, Stats stats) {
|
||||
public OpenMapTilesProfile(Translations translations, PlanetilerConfig config, Stats stats) {
|
||||
List<String> onlyLayers = config.arguments().getList("only_layers", "Include only certain layers", List.of());
|
||||
List<String> excludeLayers = config.arguments().getList("exclude_layers", "Exclude certain layers", List.of());
|
||||
|
||||
@@ -35,11 +35,11 @@ See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for deta
|
||||
*/
|
||||
// AUTOGENERATED BY Generate.java -- DO NOT MODIFY
|
||||
|
||||
package com.onthegomap.planetiler.basemap.generated;
|
||||
package com.onthegomap.planetiler.openmaptiles.generated;
|
||||
|
||||
import static com.onthegomap.planetiler.expression.Expression.*;
|
||||
|
||||
import com.onthegomap.planetiler.basemap.Layer;
|
||||
import com.onthegomap.planetiler.openmaptiles.Layer;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
@@ -68,22 +68,22 @@ public class OpenMapTilesSchema {
|
||||
/** Returns a list of expected layer implementation instances from the {@code layers} package. */
|
||||
public static List<Layer> createInstances(Translations translations, PlanetilerConfig config, Stats stats) {
|
||||
return List.of(
|
||||
new com.onthegomap.planetiler.basemap.layers.Water(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Waterway(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Landcover(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Landuse(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.MountainPeak(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Park(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Boundary(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Aeroway(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Transportation(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Building(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.WaterName(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.TransportationName(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Place(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Housenumber(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.Poi(translations, config, stats),
|
||||
new com.onthegomap.planetiler.basemap.layers.AerodromeLabel(translations, config, stats)
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Water(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Waterway(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Landcover(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Landuse(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.MountainPeak(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Park(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Boundary(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Aeroway(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Transportation(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Building(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.WaterName(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.TransportationName(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Place(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Housenumber(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.Poi(translations, config, stats),
|
||||
new com.onthegomap.planetiler.openmaptiles.layers.AerodromeLabel(translations, config, stats)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for deta
|
||||
*/
|
||||
// AUTOGENERATED BY Generate.java -- DO NOT MODIFY
|
||||
|
||||
package com.onthegomap.planetiler.basemap.generated;
|
||||
package com.onthegomap.planetiler.openmaptiles.generated;
|
||||
|
||||
import static com.onthegomap.planetiler.expression.Expression.*;
|
||||
|
||||
@@ -33,16 +33,16 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullOrEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullOrEmpty;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.basemap.util.Utils;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.Utils;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
@@ -33,11 +33,11 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
import com.onthegomap.planetiler.util.Translations;
|
||||
@@ -33,7 +33,7 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.CLASS_HEADER_BYTES;
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.POINTER_BYTES;
|
||||
@@ -45,8 +45,8 @@ import com.carrotsearch.hppc.LongObjectMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -92,11 +92,11 @@ import org.slf4j.LoggerFactory;
|
||||
*/
|
||||
public class Boundary implements
|
||||
OpenMapTilesSchema.Boundary,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
BasemapProfile.OsmRelationPreprocessor,
|
||||
BasemapProfile.OsmAllProcessor,
|
||||
BasemapProfile.FeaturePostProcessor,
|
||||
BasemapProfile.FinishHandler {
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.OsmRelationPreprocessor,
|
||||
OpenMapTilesProfile.OsmAllProcessor,
|
||||
OpenMapTilesProfile.FeaturePostProcessor,
|
||||
OpenMapTilesProfile.FinishHandler {
|
||||
|
||||
/*
|
||||
* Uses natural earth at lower zoom levels and OpenStreetMap at higher zoom levels.
|
||||
@@ -296,7 +296,7 @@ public class Boundary implements
|
||||
@Override
|
||||
public void finish(String sourceName, FeatureCollector.Factory featureCollectors,
|
||||
Consumer<FeatureCollector.Feature> emit) {
|
||||
if (BasemapProfile.OSM_SOURCE.equals(sourceName)) {
|
||||
if (OpenMapTilesProfile.OSM_SOURCE.equals(sourceName)) {
|
||||
var timer = stats.startStage("boundaries");
|
||||
LongObjectMap<PreparedGeometry> countryBoundaries = prepareRegionPolygons();
|
||||
|
||||
@@ -33,9 +33,9 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.CLASS_HEADER_BYTES;
|
||||
import static com.onthegomap.planetiler.util.Parse.parseDoubleOrNull;
|
||||
import static java.util.Map.entry;
|
||||
@@ -43,9 +43,9 @@ import static java.util.Map.entry;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
import com.onthegomap.planetiler.reader.osm.OsmElement;
|
||||
@@ -67,8 +67,8 @@ import java.util.Map;
|
||||
public class Building implements
|
||||
OpenMapTilesSchema.Building,
|
||||
Tables.OsmBuildingPolygon.Handler,
|
||||
BasemapProfile.FeaturePostProcessor,
|
||||
BasemapProfile.OsmRelationPreprocessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor,
|
||||
OpenMapTilesProfile.OsmRelationPreprocessor {
|
||||
|
||||
/*
|
||||
* Emit all buildings from OSM data at z14.
|
||||
@@ -33,11 +33,11 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
import com.onthegomap.planetiler.util.Translations;
|
||||
@@ -33,14 +33,14 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
@@ -63,9 +63,9 @@ import java.util.Set;
|
||||
*/
|
||||
public class Landcover implements
|
||||
OpenMapTilesSchema.Landcover,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
Tables.OsmLandcoverPolygon.Handler,
|
||||
BasemapProfile.FeaturePostProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor {
|
||||
|
||||
/*
|
||||
* Large ice areas come from natural earth and the rest come from OpenStreetMap at higher zoom
|
||||
@@ -33,15 +33,15 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.reader.SourceFeature;
|
||||
import com.onthegomap.planetiler.stats.Stats;
|
||||
@@ -60,7 +60,7 @@ import java.util.Set;
|
||||
*/
|
||||
public class Landuse implements
|
||||
OpenMapTilesSchema.Landuse,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
Tables.OsmLandusePolygon.Handler {
|
||||
|
||||
private static final ZoomFunction<Number> MIN_PIXEL_SIZE_THRESHOLDS = ZoomFunction.fromMaxZoomThresholds(Map.of(
|
||||
@@ -33,18 +33,18 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.elevationTags;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.elevationTags;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
|
||||
import com.carrotsearch.hppc.LongIntMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
@@ -70,11 +70,11 @@ import org.slf4j.LoggerFactory;
|
||||
* sql files</a>.
|
||||
*/
|
||||
public class MountainPeak implements
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesSchema.MountainPeak,
|
||||
Tables.OsmPeakPoint.Handler,
|
||||
Tables.OsmMountainLinestring.Handler,
|
||||
BasemapProfile.FeaturePostProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor {
|
||||
|
||||
/*
|
||||
* Mountain peaks come from OpenStreetMap data and are ranked by importance (based on if they
|
||||
@@ -33,20 +33,20 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.collection.FeatureGroup.SORT_KEY_BITS;
|
||||
|
||||
import com.carrotsearch.hppc.LongIntMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -68,7 +68,7 @@ import java.util.Locale;
|
||||
public class Park implements
|
||||
OpenMapTilesSchema.Park,
|
||||
Tables.OsmParkPolygon.Handler,
|
||||
BasemapProfile.FeaturePostProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor {
|
||||
|
||||
// constants for packing the minimum zoom ordering of park labels into the sort-key field
|
||||
private static final int PARK_NATIONAL_PARK_BOOST = 1 << (SORT_KEY_BITS - 1);
|
||||
@@ -33,20 +33,20 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullOrEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullOrEmpty;
|
||||
import static com.onthegomap.planetiler.collection.FeatureGroup.SORT_KEY_BITS;
|
||||
|
||||
import com.carrotsearch.hppc.LongIntMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -81,14 +81,14 @@ import org.locationtech.jts.geom.Point;
|
||||
*/
|
||||
public class Place implements
|
||||
OpenMapTilesSchema.Place,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
Tables.OsmContinentPoint.Handler,
|
||||
Tables.OsmCountryPoint.Handler,
|
||||
Tables.OsmStatePoint.Handler,
|
||||
Tables.OsmIslandPoint.Handler,
|
||||
Tables.OsmIslandPolygon.Handler,
|
||||
Tables.OsmCityPoint.Handler,
|
||||
BasemapProfile.FeaturePostProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor {
|
||||
|
||||
/*
|
||||
* Place labels locations and names come from OpenStreetMap, but we also join with natural
|
||||
@@ -33,21 +33,21 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfLong;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullOrEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfLong;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullOrEmpty;
|
||||
import static java.util.Map.entry;
|
||||
|
||||
import com.carrotsearch.hppc.LongIntMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
@@ -68,7 +68,7 @@ public class Poi implements
|
||||
OpenMapTilesSchema.Poi,
|
||||
Tables.OsmPoiPoint.Handler,
|
||||
Tables.OsmPoiPolygon.Handler,
|
||||
BasemapProfile.FeaturePostProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor {
|
||||
|
||||
/*
|
||||
* process() creates the raw POI feature from OSM elements and postProcess()
|
||||
@@ -33,9 +33,9 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.*;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.*;
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.CLASS_HEADER_BYTES;
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.POINTER_BYTES;
|
||||
import static com.onthegomap.planetiler.util.MemoryEstimator.estimateSize;
|
||||
@@ -44,9 +44,9 @@ import static java.util.Map.entry;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -91,10 +91,10 @@ public class Transportation implements
|
||||
Tables.OsmRailwayLinestring.Handler,
|
||||
Tables.OsmShipwayLinestring.Handler,
|
||||
Tables.OsmHighwayPolygon.Handler,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
BasemapProfile.FeaturePostProcessor,
|
||||
BasemapProfile.OsmRelationPreprocessor,
|
||||
BasemapProfile.IgnoreWikidata {
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.FeaturePostProcessor,
|
||||
OpenMapTilesProfile.OsmRelationPreprocessor,
|
||||
OpenMapTilesProfile.IgnoreWikidata {
|
||||
|
||||
/*
|
||||
* Generates the shape for roads, trails, ferries, railways with detailed
|
||||
@@ -33,12 +33,12 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.layers.Transportation.highwayClass;
|
||||
import static com.onthegomap.planetiler.basemap.layers.Transportation.highwaySubclass;
|
||||
import static com.onthegomap.planetiler.basemap.layers.Transportation.isFootwayOrSteps;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.*;
|
||||
import static com.onthegomap.planetiler.openmaptiles.layers.Transportation.highwayClass;
|
||||
import static com.onthegomap.planetiler.openmaptiles.layers.Transportation.highwaySubclass;
|
||||
import static com.onthegomap.planetiler.openmaptiles.layers.Transportation.isFootwayOrSteps;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.*;
|
||||
|
||||
import com.carrotsearch.hppc.LongArrayList;
|
||||
import com.carrotsearch.hppc.LongByteMap;
|
||||
@@ -48,10 +48,10 @@ import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.ForwardingProfile;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.reader.osm.OsmElement;
|
||||
@@ -79,8 +79,8 @@ public class TransportationName implements
|
||||
Tables.OsmHighwayLinestring.Handler,
|
||||
Tables.OsmAerialwayLinestring.Handler,
|
||||
Tables.OsmShipwayLinestring.Handler,
|
||||
BasemapProfile.FeaturePostProcessor,
|
||||
BasemapProfile.IgnoreWikidata,
|
||||
OpenMapTilesProfile.FeaturePostProcessor,
|
||||
OpenMapTilesProfile.IgnoreWikidata,
|
||||
ForwardingProfile.OsmNodePreprocessor,
|
||||
ForwardingProfile.OsmWayPreprocessor {
|
||||
|
||||
@@ -33,13 +33,13 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.Utils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.Utils;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.expression.MultiExpression;
|
||||
import com.onthegomap.planetiler.reader.SourceFeature;
|
||||
@@ -55,8 +55,8 @@ import com.onthegomap.planetiler.util.Translations;
|
||||
public class Water implements
|
||||
OpenMapTilesSchema.Water,
|
||||
Tables.OsmWaterPolygon.Handler,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
BasemapProfile.OsmWaterPolygonProcessor {
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.OsmWaterPolygonProcessor {
|
||||
|
||||
/*
|
||||
* At low zoom levels, use natural earth for oceans and major lakes, and at high zoom levels
|
||||
@@ -33,16 +33,16 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
|
||||
import com.carrotsearch.hppc.LongObjectMap;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -69,8 +69,8 @@ public class WaterName implements
|
||||
OpenMapTilesSchema.WaterName,
|
||||
Tables.OsmMarinePoint.Handler,
|
||||
Tables.OsmWaterPolygon.Handler,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
BasemapProfile.LakeCenterlineProcessor {
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.LakeCenterlineProcessor {
|
||||
|
||||
/*
|
||||
* Labels for lakes and oceans come primarily from OpenStreetMap data, but we also join
|
||||
@@ -33,20 +33,20 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
|
||||
import com.carrotsearch.hppc.LongObjectHashMap;
|
||||
import com.google.common.util.concurrent.AtomicDouble;
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.FeatureMerge;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.basemap.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.basemap.generated.Tables;
|
||||
import com.onthegomap.planetiler.basemap.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.basemap.util.Utils;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.OpenMapTilesSchema;
|
||||
import com.onthegomap.planetiler.openmaptiles.generated.Tables;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.LanguageUtils;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.Utils;
|
||||
import com.onthegomap.planetiler.collection.Hppc;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
@@ -70,10 +70,10 @@ import java.util.Map;
|
||||
public class Waterway implements
|
||||
OpenMapTilesSchema.Waterway,
|
||||
Tables.OsmWaterwayLinestring.Handler,
|
||||
BasemapProfile.FeaturePostProcessor,
|
||||
BasemapProfile.NaturalEarthProcessor,
|
||||
BasemapProfile.OsmRelationPreprocessor,
|
||||
BasemapProfile.OsmAllProcessor {
|
||||
OpenMapTilesProfile.FeaturePostProcessor,
|
||||
OpenMapTilesProfile.NaturalEarthProcessor,
|
||||
OpenMapTilesProfile.OsmRelationPreprocessor,
|
||||
OpenMapTilesProfile.OsmAllProcessor {
|
||||
|
||||
/*
|
||||
* Uses Natural Earth at lower zoom-levels and OpenStreetMap at higher zoom levels.
|
||||
@@ -33,10 +33,10 @@ Design license: CC-BY 4.0
|
||||
|
||||
See https://github.com/openmaptiles/openmaptiles/blob/master/LICENSE.md for details on usage
|
||||
*/
|
||||
package com.onthegomap.planetiler.basemap.util;
|
||||
package com.onthegomap.planetiler.openmaptiles.util;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.nullIfEmpty;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.nullIfEmpty;
|
||||
|
||||
import com.onthegomap.planetiler.util.Translations;
|
||||
import java.util.HashMap;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.util;
|
||||
package com.onthegomap.planetiler.openmaptiles.util;
|
||||
|
||||
import com.onthegomap.planetiler.util.Parse;
|
||||
import java.util.Map;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.util;
|
||||
package com.onthegomap.planetiler.openmaptiles.util;
|
||||
|
||||
import com.onthegomap.planetiler.mbtiles.Mbtiles;
|
||||
import com.onthegomap.planetiler.mbtiles.Verify;
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import static com.onthegomap.planetiler.basemap.Generate.parseYaml;
|
||||
import static com.onthegomap.planetiler.openmaptiles.Generate.parseYaml;
|
||||
import static com.onthegomap.planetiler.expression.Expression.*;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.DynamicTest.dynamicTest;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
@@ -11,12 +11,12 @@ import com.onthegomap.planetiler.util.Wikidata;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
class BasemapProfileTest {
|
||||
class OpenMapTilesProfileTest {
|
||||
|
||||
private final Wikidata.WikidataTranslations wikidataTranslations = new Wikidata.WikidataTranslations();
|
||||
private final Translations translations = Translations.defaultProvider(List.of("en", "es", "de"))
|
||||
.addTranslationProvider(wikidataTranslations);
|
||||
private final BasemapProfile profile = new BasemapProfile(translations, PlanetilerConfig.defaults(),
|
||||
private final OpenMapTilesProfile profile = new OpenMapTilesProfile(translations, PlanetilerConfig.defaults(),
|
||||
Stats.inMemory());
|
||||
|
||||
@Test
|
||||
@@ -1,15 +1,15 @@
|
||||
package com.onthegomap.planetiler.basemap;
|
||||
package com.onthegomap.planetiler.openmaptiles;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.assertContains;
|
||||
import static com.onthegomap.planetiler.TestUtils.assertFeatureNear;
|
||||
import static com.onthegomap.planetiler.basemap.util.VerifyMonaco.MONACO_BOUNDS;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.VerifyMonaco.MONACO_BOUNDS;
|
||||
import static com.onthegomap.planetiler.util.Gzip.gunzip;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.DynamicTest.dynamicTest;
|
||||
|
||||
import com.onthegomap.planetiler.TestUtils;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.util.VerifyMonaco;
|
||||
import com.onthegomap.planetiler.openmaptiles.util.VerifyMonaco;
|
||||
import com.onthegomap.planetiler.config.Arguments;
|
||||
import com.onthegomap.planetiler.mbtiles.Mbtiles;
|
||||
import java.io.IOException;
|
||||
@@ -30,12 +30,12 @@ import org.locationtech.jts.geom.Point;
|
||||
import org.locationtech.jts.geom.Polygon;
|
||||
|
||||
/**
|
||||
* End-to-end tests for basemap generation.
|
||||
* End-to-end tests for OpenMapTiles generation.
|
||||
* <p>
|
||||
* Generates an entire map for the smallest openstreetmap extract available (Monaco) and asserts that expected output
|
||||
* features exist
|
||||
*/
|
||||
class BasemapTest {
|
||||
class OpenMapTilesTest {
|
||||
|
||||
@TempDir
|
||||
static Path tmpDir;
|
||||
@@ -44,7 +44,7 @@ class BasemapTest {
|
||||
@BeforeAll
|
||||
public static void runPlanetiler() throws Exception {
|
||||
Path dbPath = tmpDir.resolve("output.mbtiles");
|
||||
BasemapMain.run(Arguments.of(
|
||||
OpenMapTilesMain.run(Arguments.of(
|
||||
// Override input source locations
|
||||
"osm_path", TestUtils.pathToResource("monaco-latest.osm.pbf"),
|
||||
"natural_earth_path", TestUtils.pathToResource("natural_earth_vector.sqlite.zip"),
|
||||
@@ -1,18 +1,18 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.assertSubmap;
|
||||
import static com.onthegomap.planetiler.TestUtils.newLineString;
|
||||
import static com.onthegomap.planetiler.TestUtils.newPoint;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.util.Utils.coalesce;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.Utils.coalesce;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.fail;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.TestUtils;
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
@@ -37,7 +37,7 @@ public abstract class AbstractLayerTest {
|
||||
.addTranslationProvider(wikidataTranslations);
|
||||
|
||||
final PlanetilerConfig params = PlanetilerConfig.defaults();
|
||||
final BasemapProfile profile = new BasemapProfile(translations, PlanetilerConfig.defaults(),
|
||||
final OpenMapTilesProfile profile = new OpenMapTilesProfile(translations, PlanetilerConfig.defaults(),
|
||||
Stats.inMemory());
|
||||
final Stats stats = Stats.inMemory();
|
||||
final FeatureCollector.Factory featureCollectorFactory = new FeatureCollector.Factory(params, stats);
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newLineString;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.assertNull;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import com.onthegomap.planetiler.VectorTile;
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
import com.onthegomap.planetiler.reader.SimpleFeature;
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newPoint;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
import java.util.List;
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newPoint;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.layers.Place.getSortKey;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.layers.Place.getSortKey;
|
||||
import static com.onthegomap.planetiler.collection.FeatureGroup.SORT_KEY_MAX;
|
||||
import static com.onthegomap.planetiler.collection.FeatureGroup.SORT_KEY_MIN;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newLineString;
|
||||
import static com.onthegomap.planetiler.TestUtils.newPoint;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
import com.onthegomap.planetiler.basemap.BasemapProfile;
|
||||
import com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile;
|
||||
import com.onthegomap.planetiler.config.Arguments;
|
||||
import com.onthegomap.planetiler.config.PlanetilerConfig;
|
||||
import com.onthegomap.planetiler.geo.GeometryException;
|
||||
@@ -400,7 +400,7 @@ class TransportationTest extends AbstractLayerTest {
|
||||
"highway", "tertiary"
|
||||
))));
|
||||
|
||||
var profileWithMinorRefs = new BasemapProfile(translations, PlanetilerConfig.from(Arguments.of(Map.of(
|
||||
var profileWithMinorRefs = new OpenMapTilesProfile(translations, PlanetilerConfig.from(Arguments.of(Map.of(
|
||||
"transportation_name_minor_refs", "true"
|
||||
))), Stats.inMemory());
|
||||
|
||||
@@ -1225,7 +1225,7 @@ class TransportationTest extends AbstractLayerTest {
|
||||
|
||||
@Test
|
||||
void testTransportationNameLayerRequiresTransportationLayer() {
|
||||
var profile = new BasemapProfile(translations, PlanetilerConfig.from(Arguments.of(
|
||||
var profile = new OpenMapTilesProfile(translations, PlanetilerConfig.from(Arguments.of(
|
||||
"only_layers", "transportation_name"
|
||||
)), Stats.inMemory());
|
||||
SourceFeature feature = lineFeature(Map.of(
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newLineString;
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.LAKE_CENTERLINE_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.LAKE_CENTERLINE_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
|
||||
import com.onthegomap.planetiler.TestUtils;
|
||||
import com.onthegomap.planetiler.geo.GeoUtils;
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.rectangle;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.WATER_POLYGON_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.WATER_POLYGON_SOURCE;
|
||||
|
||||
import com.onthegomap.planetiler.reader.SimpleFeature;
|
||||
import java.util.List;
|
||||
@@ -1,8 +1,8 @@
|
||||
package com.onthegomap.planetiler.basemap.layers;
|
||||
package com.onthegomap.planetiler.openmaptiles.layers;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.newLineString;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.basemap.BasemapProfile.OSM_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.NATURAL_EARTH_SOURCE;
|
||||
import static com.onthegomap.planetiler.openmaptiles.OpenMapTilesProfile.OSM_SOURCE;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import com.onthegomap.planetiler.FeatureCollector;
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.onthegomap.planetiler.basemap.util;
|
||||
package com.onthegomap.planetiler.openmaptiles.util;
|
||||
|
||||
import static com.onthegomap.planetiler.TestUtils.assertSubmap;
|
||||
import static com.onthegomap.planetiler.basemap.util.LanguageUtils.containsOnlyLatinCharacters;
|
||||
import static com.onthegomap.planetiler.openmaptiles.util.LanguageUtils.containsOnlyLatinCharacters;
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||
import static org.junit.jupiter.api.Assertions.assertNull;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.onthegomap.planetiler.basemap.util;
|
||||
package com.onthegomap.planetiler.openmaptiles.util;
|
||||
|
||||
import static com.onthegomap.planetiler.geo.GeoUtils.point;
|
||||
import static com.onthegomap.planetiler.util.Gzip.gzip;
|
||||
Reference in New Issue
Block a user