Skip to content

Latest commit

 

History

History
34 lines (28 loc) · 776 Bytes

README.md

File metadata and controls

34 lines (28 loc) · 776 Bytes

Java2GeoJSON

Your geographic information model, exported to valid GeoJSON

Usage

A GeoFeature describes a container of layers. Each of these layers may contain a set of geographic elements.

  • Building a linestring
GeoFeature[] parsePath(Node[] path){
	//Generate GeoJson objects
	GeoFeature pathLayer = new GeoFeature();
	GeoPolyline path = new GeoPolyline();		
	for (Node node : path) {						
		float lat = node.getLat();
		float lng = node.getLng();
		path.addCoordinate(lat, lng);									
	}
	pathLayer.setGeometry(path);
	return new GeoFeature[]{pathLayer};
}

Dependencies

For more information visit: www.geojson.com.ar