User's Guide and Reference
A multilinestring is a collection of linestrings. Multilinestrings
are simple if they intersect only at the endpoints of the linestring
elements. Multilinestrings are non-simple if the interiors of the
linestring elements intersect.
The boundary of a multilinestring is the non-intersected endpoints of the
linestring elements. The multilinestring is closed if all of its
linestring elements are closed. The boundary of a multilinestring is
NULL if all of the endpoints of all of the elements are intersected. In
addition to the other properties inherited from the superclass geometry,
multilinestrings have length. Multilinestrings are used to define
streams or road networks.
Functions that operate on multilinestrings:
-
ST_Length
- Takes a multilinestring and returns the cumulative length of all its
linestring elements as a double precision number. For more information,
see ST_Length.
-
ST_IsClosed
- Takes a multilinestring and returns 1 (TRUE) if the multilinestring is
closed and 0 (FALSE) otherwise. For more information, see ST_IsClosed.
- ST_NumGeometries
- Takes a homogeneous collection and returns the number of base geometry
elements it contains. For more information, see ST_NumGeometries.
- ST_GeometryN
- Takes a homogeneous collection and an index and returns the nth base
geometry. For more information, see ST_GeometryN.
Figure 12. Multilinestrings.
- A simple multilinestring whose boundary is defined by the four endpoints of its two linestring elements.
- A simple multilinestring because only the endpoints of the linestring elements intersect. The boundary is defined by the two non-intersecting endpoints.
- A non-simple linestring because the interior of one of its linestring elements is intersected. The boundary of this multilinestring is defined by the four endpoints, including the intersecting point.
- A simple non-closed multilinestring. It is not closed because its element linestrings are not closed. It is simple because none of the interiors of any of the element linestrings are intersected.
- A simple closed multilinestring. It is closed because all of its elements are closed. It is simple because none of its elements are intersected at the interiors.
[ Top of Page | Previous Page | Next Page ]