Skip to content

Commit

Permalink
Add note about toTopoGeom
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/postgis/trunk@9481 b70326c6-7e19-0410-871a-916f4a2858ee
  • Loading branch information
strk committed Mar 13, 2012
1 parent e5489f8 commit 198a9d1
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions topology/README
Original file line number Diff line number Diff line change
Expand Up @@ -170,13 +170,26 @@ For Hierarchical TopoGeometry objects this would be:

{{child_layer_id, topogeoemtry_id}, ...}

==Getting simple Geometry values from TopoGeometry objects
==Converting Geometry to TopoGeometry while populating the topology

You can import a Geometry into an existing topology and at the same
time get its topological definition (its TopoGeometry equivalent)
using the toTopoGeom function:

topology.toTopoGeom(

geometry, -- the simple geometry

You currently need to explicit call the TopoGeometry=>Geometry
cast function. This will probably be made implicit when the
code is more tested:
topology_name,

layer_id -- as returned by AddTopoGeometryColumn
);

==Getting simple Geometry values from TopoGeometry objects

SELECT topology.Geometry(TopoGeometry);
TopoGeometry to Geometry casting is implicit, so any function accepting
a Geometry would transparently also accept a TopoGeometry. Some functions
may be optimized for TopoGeometry.

=Issues

Expand Down

0 comments on commit 198a9d1

Please sign in to comment.