Compartilhar via


Método SqlGeometry.STCentroid

Returns the geometric center of a SqlGeometry instance consisting of one or more polygons.

Namespace:  Microsoft.SqlServer.Types
Assembly:  Microsoft.SqlServer.Types (em Microsoft.SqlServer.Types.dll)

Sintaxe

'Declaração
<SqlMethodAttribute(IsDeterministic := True, IsPrecise := False)> _
Public Function STCentroid As SqlGeometry
'Uso
Dim instance As SqlGeometry 
Dim returnValue As SqlGeometry 

returnValue = instance.STCentroid()
[SqlMethodAttribute(IsDeterministic = true, IsPrecise = false)]
public SqlGeometry STCentroid()
[SqlMethodAttribute(IsDeterministic = true, IsPrecise = false)]
public:
SqlGeometry^ STCentroid()
[<SqlMethodAttribute(IsDeterministic = true, IsPrecise = false)>]
member STCentroid : unit -> SqlGeometry
public function STCentroid() : SqlGeometry

Valor de retorno

Tipo: Microsoft.SqlServer.Types.SqlGeometry
A SqlGeometry object that represents the geometric center of the calling SqlGeometry.

Comentários

STCentroid returns null if the SqlGeometry instance is not a Polygon or MultiPolygon type.

Consulte também

Referência

SqlGeometry Classe

Namespace Microsoft.SqlServer.Types