#tile #vms2 #locr

vms2-tile-db-reader

A class for reading tile data from a database

6 releases

0.1.5 Oct 28, 2024
0.1.4 Oct 25, 2024

#368 in Database interfaces

Download history 339/week @ 2024-10-15 198/week @ 2024-10-22 87/week @ 2024-10-29

624 downloads per month

MIT license

20KB
255 lines

Vms2TileDbReader

license github_workflow_status codecov Quality Gate Status github_tag Crates.io

This is the rust version of the repository from https://github.com/locr-company/php-vms2-tile-db-reader

Installation

cd /path/to/your/rust/project
cargo add vms2-tile-db-reader

Basic Usage

use std::path::Path;

use vms2_tile_db_reader::{
    data_type::DataType,
    sources::Source,
    sources::SQLite
};

let tile_db = SQLite::new(Path::new("germany.sqlite")).unwrap();
let tile_data = tile_db.get_raw_data(
    34686,
    21566,
    16,
    String::from("building"),
    Some(String::from("*")),
    Some(DataType::Polygons)
).unwrap();

// do something with tile_data.

Dependencies

~22MB
~428K SLoC