名稱

ST_GetFaceEdges — 返回一組有序的邊,這些邊界定了 aface

概要

getfaceedges_returntype ST_GetFaceEdges(varchar atopology, integer aface);

描述

返回一組有序的邊,這些邊界定了 aface。每個輸出包含一個序列和邊的 ID。序列號從值 1 開始。

每個環的邊的枚舉從具有最小識別碼的邊開始。邊的順序遵循左手定則(邊界面的左側是每個有向邊)。

可用性:2.0

此方法實現了 SQL/MM 規範。SQL-MM 3 Topo-Geo 和 Topo-Net 3:例行詳情:X.3.5

範例

-- Returns the edges bounding face 1
SELECT (topology.ST_GetFaceEdges('tt', 1)).*;
-- result --
 sequence | edge
----------+------
        1 |   -4
        2 |    5
        3 |    7
        4 |   -6
        5 |    1
        6 |    2
        7 |    3
(7 rows)
-- Returns the sequence, edge id
-- and geometry of the edges that bound face 1
-- If you just need geom and seq, can use ST_GetFaceGeometry
SELECT t.seq, t.edge, geom
FROM topology.ST_GetFaceEdges('tt',1) As t(seq,edge)
	INNER JOIN tt.edge AS e ON abs(t.edge) = e.edge_id;