A module to support OGC geopackage with sqlite.
At the moment, the vector (features) part of geopackage is supported.
View the example README for instructions on how to integrate it in an app.
Geopackage Example App
VERY IMPORTANT REGARDING THE EXAMPLE APP #
The example app works only on Android due to its dependence on the storage path of the test geopackage database. IOS users will need to change the path from which the geopackage database is pulled. No big issue, but it is not automatic yet (pull requests are welcome, I don't really care about IOS at the time being, so it might take a while before I do it).
For the example to work, you need to copy the gdal_sample.gpkg file that is in the test folder of the main library (flutter_geopackage) to the main storage of the device, i.e. it has to be available in /storage/emulated/0/gdal_sample.gpkg since the path is hardcoded (see above comment).
Use this package as a library
1. Depend on it
Add this to your package's pubspec.yaml file:
dependencies: flutter_geopackage: ^0.0.1
2. Install it
You can install packages from the command line:
$ flutter pub get
Alternatively, your editor might support
flutter pub get.
Check the docs for your editor to learn more.
3. Import it
Now in your Dart code, you can use:
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
We analyzed this package on Dec 13, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
- Dart: 2.6.1
- pana: 0.13.1+4
- Flutter: 1.12.13+hotfix.2
lib/com/hydrologis/flutter_geopackage/core/utils.dart. (-9.08 points)
lib/com/hydrologis/flutter_geopackage/core/utils.dart reported 19 hints, including:
line 11 col 1: Prefer using /// for doc comments.
line 19 col 3: Prefer using /// for doc comments.
line 24 col 3: Prefer using /// for doc comments.
line 29 col 3: Prefer using /// for doc comments.
line 34 col 3: Prefer using /// for doc comments.
lib/com/hydrologis/flutter_geopackage/geopackage.dart. (-8.63 points)
lib/com/hydrologis/flutter_geopackage/geopackage.dart reported 18 hints, including:
line 7 col 23: Name non-constant identifiers using lowerCamelCase.
line 9 col 23: Name non-constant identifiers using lowerCamelCase.
line 11 col 23: Name non-constant identifiers using lowerCamelCase.
line 13 col 23: Name non-constant identifiers using lowerCamelCase.
line 15 col 23: Name non-constant identifiers using lowerCamelCase.
lib/com/hydrologis/flutter_geopackage/core/geom.dart. (-1.99 points)
lib/com/hydrologis/flutter_geopackage/core/geom.dart reported 4 hints:
line 154 col 32: Name non-constant identifiers using lowerCamelCase.
line 244 col 9: The value of the local variable 'b1' isn't used.
line 245 col 9: The value of the local variable 'b2' isn't used.
line 246 col 9: The value of the local variable 'b3' isn't used.
lib/flutter_geopackage.dart. (-1.49 points)
lib/flutter_geopackage.dart reported 3 hints:
line 4 col 8: Unused import: 'dart:collection'.
line 8 col 8: Unused import: 'dart:math'.
line 11 col 8: Duplicate import.
Maintenance issues and suggestions
Provide a file named
CHANGELOG.md. (-20 points)
Changelog entries help developers follow the progress of your package. See the example generated by
The package description is too short. (-13 points)
Add more detail to the
description field of
pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.
Package is pre-v0.1 release. (-10 points)
While nothing is inherently wrong with versions of
0.0.*, it might mean that the author is still experimenting with the general direction of the API.
|Dart SDK||>=2.1.0 <3.0.0|