GeoTools : OGR Data Store


OGR data store

Module Maintainer:

Andrea Aime

Email Help:



(star) (star)


OGR Data Store design

User doc

OGR Data Store user guide

Gold Star Quality Assurance Check:

(star) IP Check: need to ensure all headers are in place
(star) user and design docs. Module maintainer does watches user list, answers email.


A module dedicated to integrate the OGR Simple Features Library into GeoTools as a DataStore implementation.


OGR is a C++ open source library providing read (and sometimes write) access to a variety of vector file formats including, among the others, S-57, SDTS, Mapinfo TAB formats, ESRI personal GeoDatabase, GRASS, Microstation DGN (see full list in the OGR Vector Formats page).

The list of supported formats is long, and includes significant formats that are not supported by pure java GeoTools data stores. An integration that leverages the work done by OGR provides good value with a relatively low effort, and opens the door for the ever growing set of OGR supported formats, at least one the read side (for issues with the write side, the the design docs).

Target Audience

This module is appealing to anyone needing to open and serve contents of spatial data files that are supported by OGR, but not natively by pure java GeoTools data stores. Initial support focuses on feature reading, and for OGR drivers supporting it, write in append mode.

Quality Assurance

Unit test coverage

The module targets a high level of code coverage (raw numbers pending).

Unit testing strategy

Unit tests do focus on getting high code coverage level by using a driver with full capabilities and an easy GeoTools reference to be used for comparison: the shapefile format.
The ShapefileDataStore tests are being reused extensively to make sure the OGR datastore is as capable as the native GeoTools one.
The downside of this testing strategy is that the datastore is not tested with formats not enjoing an equally complete driver (say, formats that do only support feature appending, or that loose random access capabilities once a spatial filter is attached to them).


The module is in early alpha stage. It requires users to either download and use a native OGR build, available for selected operating systems on the user guide, or to provide their own compiled version (both library and java bindings).