1、spatialite操作手册:
spatialite支持的格式:
- Well-Known Text (WKT) format
- Well-Known Binary (WKB) format
- Internal BLOB format [the one used by SpatiaLite to store geometries in SQLite columns]
SELECT AsText(geometry) FROM table;这就把数据读取出来
2、GeometryEngine 参考:
jsonToGeometry
public static jsonToGeometry(org.codehaus.jackson.JsonParser json)
- Imports the MapGeometry from it's JSON representation. M and Z values are not imported from JSON representation.
-
- Parameters:
-
json
- The JSON representation of the geometry (with spatial reference). Returns: - The MapGeometry instance containing the imported geometry and it's spatial reference.
-
3、想法:数据存在spatialite里面,用SELECT AsText(geometry) FROM table选取出来,然后把WKT专成json,最后用jsonToGeometry生成Geometry实现地图的绘制。