I tend to stage that kind of information in PostGIS and then render the
views in GeoTools. See something like
http://postgis.net/docs/ST_MakeLine.html
--
Jody Garnett
On 1 December 2014 at 08:28, Peter Borissow <peter.boris...@yahoo.com>
wrote:
> Now that I'm finally able to render simple maps with GeoTools, I would
> like to start rendering OSM data.
>
> I have loaded a subset of the OSM data into a PostgreSQL database using
> osmosis. For a variety of reasons, I do not want to use osm2pgsql.
>
> From a "traditional" GIS perspective, the osmosis schema is a little
> unusual. First off, there no points, lines, and polygons per se. Instead
> there are nodes, ways, and relationships.
>
> Also, osmosis uses hstore to store osm tags (attribute information for
> nodes, ways, etc).
>
> I want to be able to select features like roads or points of interest and
> generate a map. For example:
>
> (1) Query the osm database to find all places of worship:
> SELECT *
> FROM nodes
> WHERE tags->'amenity'= 'place_of_worship' AND tags->'religion'= 'christian'
>
> (2) Grab results and generate a map.
>
> Rendering nodes is relatively simple. Getting lines and polygons are a
> little trickier.
>
> Before I reinvent the wheel, does anyone have a working example that they
> would like to share? I don't need a fancy data store like the
> ShapefileDataStore. I just need something that can serialize entries in the
> nodes, ways, and relations table into JTS geometries line
> com.vividsolutions.jts.geom.Polygon,
> com.vividsolutions.jts.geom.LineString, etc.
>
> Thanks,
> Peter
>
>
>
>
>
> ------------------------------------------------------------------------------
> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
> with Interactivity, Sharing, Native Excel Exports, App Integration & more
> Get technology previously reserved for billion-dollar corporations, FREE
>
> http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
> _______________________________________________
> GeoTools-GT2-Users mailing list
> GeoTools-GT2-Users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users
>
>
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users