From: Sandro Santilli Date: Tue, 13 Mar 2012 09:17:46 +0000 (+0000) Subject: Add note about toTopoGeom X-Git-Tag: 2.0.0beta3~16 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=17aad4599b42ae29d79eeb6a91a80a2267b2c941;p=postgis Add note about toTopoGeom git-svn-id: http://svn.osgeo.org/postgis/trunk@9481 b70326c6-7e19-0410-871a-916f4a2858ee --- diff --git a/topology/README b/topology/README index 4737f4e1d..a2d17683d 100644 --- a/topology/README +++ b/topology/README @@ -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