spatial.decodeGeometry
Function
Returns a geometry of a layer node as the Neo4j geometry type, to be passed to other procedures or returned to a client
Input parameters
| Name | Type | Default | Description |
|---|---|---|---|
layerName |
STRING |
null |
The name of the layer used to select the appropriate geometry encoder for extracting the Neo4j geometry. |
node |
NODE |
null |
An indexed node to extract the neo4j geometry from |
Examples
Decode a geometry from a node property
Create a WKT layer
CALL spatial.addWKTLayer('geom','geom')
| node |
|---|
|
Decode a geometry
CREATE (n:Node {geom:'POINT(4.0 5.0)'}) RETURN spatial.decodeGeometry('geom',n) AS geometry
| geometry |
|---|
point({x: 4.0, y: 5.0, crs: 'cartesian'}) |