STIsClosed (tipo di dati geography)
Restituisce 1 se i punti di inizio e di fine dell'istanza geography specificata sono gli stessi. Restituisce 1 per i tipi relativi a una raccolta geography se ogni istanza geography contenuta è chiusa. Restituisce 0 se l'istanza non è chiusa.
Sintassi
.STIsClosed ( )
Tipi restituiti
Tipo SQL Server restituito: bitbit
Tipo CLR restituito: SqlBooleanSqlBoolean
Osservazioni
Questo metodo restituisce 0 se qualsiasi figura di un'istanza geography è costituita da punti o se l'istanza è vuota.
Tutte le istanze Polygon sono considerate chiuse.
Esempi
Nell'esempio seguente viene creata un'istanza Polygon e viene utilizzato STIsClosed() per verificare se l'istanza Polygon è chiusa.
DECLARE @g geography;
SET @g = geography::STGeomFromText('POLYGON((-122.358 47.653, -122.348 47.649, -122.348 47.658, -122.358 47.658, -122.358 47.653))', 4326);
SELECT @g.STIsClosed();