Skip to content
tschaub edited this page Sep 13, 2010 · 5 revisions

GeoScript

GeoScript provides scripting access to various Java geo-libraries. The goal is to provide basic geospatial data access, manipulation, and rendering functionality with dynamic scripting languages.

Current Implementations:

Design

The geom module

The geom module allows for easy construction and manipulation of geometries. In general, geometry constructors take a coordinates array as their first argument. The structure of this coordinates array depends on the geometry type. For points, coordinates is a one-dimensional array (with one item for each axis). The coordinates array for lines is an array of point coordinates. The coordinates array for polygons is an array of ring coordinates (similar to line coordinates but closed). See the GeoJSON examples for more.


js> var geom = require('geoscript/geom');
js> var p = new geom.Point([1, 2]);
js> p.x
1
js> p.y
2

Clone this wiki locally