Поделиться через


Класс SqlGeometry

The SqlGeometry type represents data in a Euclidean (flat) coordinate system.

Иерархия наследования

System.Object
  Microsoft.SqlServer.Types.SqlGeometry

Пространство имен:  Microsoft.SqlServer.Types
Сборка:  Microsoft.SqlServer.Types (в Microsoft.SqlServer.Types.dll)

Синтаксис

'Декларация
<SerializableAttribute> _
<SqlUserDefinedTypeAttribute(Format.UserDefined, IsByteOrdered := False,  _
    MaxByteSize := , IsFixedLength := False)> _
<CLSCompliantAttribute(True)> _
Public NotInheritable Class SqlGeometry _
    Implements INullable, IBinarySerialize, ISqlSpatialGridIndexable
'Применение
Dim instance As SqlGeometry
[SerializableAttribute]
[SqlUserDefinedTypeAttribute(Format.UserDefined, IsByteOrdered = false, 
    MaxByteSize = , IsFixedLength = false)]
[CLSCompliantAttribute(true)]
public sealed class SqlGeometry : INullable, 
    IBinarySerialize, ISqlSpatialGridIndexable
[SerializableAttribute]
[SqlUserDefinedTypeAttribute(Format::UserDefined, IsByteOrdered = false, 
    MaxByteSize = , IsFixedLength = false)]
[CLSCompliantAttribute(true)]
public ref class SqlGeometry sealed : INullable, 
    IBinarySerialize, ISqlSpatialGridIndexable
[<SealedAttribute>]
[<SerializableAttribute>]
[<SqlUserDefinedTypeAttribute(Format.UserDefined, IsByteOrdered = false, 
    MaxByteSize = , IsFixedLength = false)>]
[<CLSCompliantAttribute(true)>]
type SqlGeometry =  
    class 
        interface INullable 
        interface IBinarySerialize 
        interface ISqlSpatialGridIndexable 
    end
public final class SqlGeometry implements INullable, IBinarySerialize, ISqlSpatialGridIndexable

Тип SqlGeometry обеспечивает доступ к следующим элементам.

Конструкторы

  Имя Описание
Открытый метод SqlGeometry Initializes a new instance of the SqlGeometry class.

В начало

Свойства

  Имя Описание
Открытое свойство HasM Returns true if at least one point in a spatial object contains value M; otherwise returns false. This property is read-only.
Открытое свойство HasZ Returns true if at least one point in a spatial object contains value Z; otherwise returns false. This property is read-only.
Открытое свойство IsNull Gets a value that indicates whether the SqlGeometry object is null.
Открытое свойство M Gets the M (measure) value of the SqlGeometry instance. The semantics of the measure value are user-defined.
Открытое свойствоСтатический элемент Null Gets a read-only property providing a null instance of the SqlGeometry type.
Открытое свойство STSrid Gets or sets an integer that represents the Spatial Reference Identifier (SRID) of the instance.
Открытое свойство STX Gets the X-coordinate property of a Point instance.
Открытое свойство STY Gets the Y-coordinate property of a Point instance.
Открытое свойство Z Gets the Z (elevation) value of the instance. The semantics of the elevation value are user-defined.

В начало

Методы

  Имя Описание
Открытый метод AsBinaryZM Returns the Elevation and Measure as a binary.
Открытый метод AsGml Returns the Geography Markup Language (GML) representation of a SqlGeometry instance.
Открытый метод AsTextZM Returns the Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation of a SqlGeometry instance, augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый метод BufferWithCurves Buffers the geometry objects with curves.
Открытый метод BufferWithTolerance Returns a geometric object that represents the union of all point values whose distance from a SqlGeometry instance is less than or equal to a specified value, allowing for a specified tolerance.
Открытый метод CurveToLineWithTolerance Returns a polygonal approximation of a SqlGeometry instance that contains circular arc segments.
Открытый методСтатический элемент Deserialize Returns a constructed SqlGeometry from an internal SQL Server format for spatial data.
Открытый метод Equals (Производный от Object.)
Открытый метод Filter Offers a fast, index-only intersection method to determine if a SqlGeometry instance intersects another SqlGeometry instance, assuming an index is available.
Открытый методСтатический элемент GeomFromGml Constructs a SqlGeometry instance given a representation in the SQL Server subset of the Geography Markup Language (GML).
Открытый метод GetHashCode (Производный от Object.)
Открытый метод GetType (Производный от Object.)
Открытый метод InstanceOf Tests if the SqlGeometry instance is the same as the specified type.
Открытый метод IsValidDetailed Returns a message to help identify validity issues with a spatial object.
Открытый метод MakeValid Converts an invalid SqlGeometry instance into a SqlGeometry instance with a valid Open Geospatial Consortium (OGC) type.
Открытый метод MinDbCompatibilityLevel Returns the minimum database compatibility that accepts the SqlGeometry type.
Открытый методСтатический элемент Parse Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation.
Открытый методСтатический элемент Point Constructs a SqlGeometry instance that represents a Point instance from its X and Y values and an SRID.
Открытый метод Populate(IGeometrySink) Устарело. Applies a geometry type call sequence to an IGeometrySink object. The call sequence is a sequential set of figures, lines, and points. SqlGeometry
Открытый метод Populate(IGeometrySink110) Applies a geometry type call sequence to IGeometrySink object.
Открытый метод Read Reads a binary representation of a geometry type into a SqlGeometry object. SqlGeometry
Открытый метод Reduce Returns an approximation of the given SqlGeometry instance produced by running the Douglas-Peucker algorithm on the instance with the given tolerance.
Открытый метод Serialize Returns the bytes that represent an internal SQL Server format of SqlGeometry type.
Открытый метод ShortestLineTo Returns the shortest distance between the two SqlGeometryinstances.
Открытый метод STArea Returns the total surface area of a SqlGeometry instance.
Открытый метод STAsBinary Returns the Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation of a SqlGeometry instance. This value will not contain any Z or M values carried by the instance.
Открытый метод STAsText Returns the Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation of a SqlGeometry instance. This text will not contain any Z (elevation) or M (measure) values carried by the instance.
Открытый метод STBoundary Returns the boundary of a SqlGeometry instance.
Открытый метод STBuffer Returns a geometric object that represents the union of all points whose distance from a SqlGeometry instance is less than or equal to a specified value.
Открытый метод STCentroid Returns the geometric center of a SqlGeometry instance consisting of one or more polygons.
Открытый метод STContains Specifies whether the calling SqlGeometry instance completely contains another SqlGeometry.
Открытый метод STConvexHull Returns an object that represents the convex hull of a SqlGeometry instance.
Открытый метод STCrosses Determines whether the calling SqlGeometry instance crosses the specified SqlGeometry instance.
Открытый метод STCurveN Returns the curve specified from a SqlGeometry instance that is a LineString, CircularString, or CompoundCurve.
Открытый метод STCurveToLine Returns a polygonal approximation of a SqlGeometry instance that contains circular arc segments.
Открытый метод STDifference Returns an object that represents the points from one SqlGeometry instance that do not lie within another SqlGeometry instance.
Открытый метод STDimension Returns the maximum dimension of a SqlGeometry instance.
Открытый метод STDisjoint Determines whether the calling SqlGeometry instance is disjointed when compared against the specified SqlGeometry.
Открытый метод STDistance Returns the shortest distance between a point in a SqlGeometry instance and a point in the specified SqlGeometry instance.
Открытый метод STEndPoint Returns the end point of a SqlGeometry instance.
Открытый метод STEnvelope Returns the minimum axis-aligned bounding rectangle of the instance.
Открытый метод STEquals Determines whether the specified SqlGeometry has a point set identical to the calling SqlGeometry.
Открытый метод STExteriorRing Returns the exterior ring of a SqlGeometry instance that is a polygon.
Открытый методСтатический элемент STGeomCollFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STGeomCollFromWKB Returns a SqlGeometry collection instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый метод STGeometryN Returns the specified SqlGeometry in a SqlGeometry collection.
Открытый метод STGeometryType Returns the Open Geospatial Consortium (OGC) type name represented by a geometry instance. SqlGeometry
Открытый методСтатический элемент STGeomFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STGeomFromWKB Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый метод STInteriorRingN Returns the specified interior ring of a Polygon SqlGeometry instance.
Открытый метод STIntersection Returns an object that represents the points where a SqlGeometry instance intersects another SqlGeometry instance.
Открытый метод STIntersects Determines whether the calling SqlGeometry instance intersects another SqlGeometry.
Открытый метод STIsClosed Determines whether the start and end points of the calling SqlGeometry are the same.
Открытый метод STIsEmpty Indicates whether the calling SqlGeometry instance is empty.
Открытый метод STIsRing Determines whether the calling SqlGeometry instance is a ring.
Открытый метод STIsSimple Determines whether the calling SqlGeometry instance is simple.
Открытый метод STIsValid Determines whether the SqlGeometry instance is well-formed.
Открытый метод STLength Returns the total length of the elements in a SqlGeometry instance.
Открытый методСтатический элемент STLineFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STLineFromWKB Returns a SqlGeometry LineString instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый методСтатический элемент STMLineFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STMLineFromWKB Returns a SqlGeometry MultiLineString instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый методСтатический элемент STMPointFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STMPointFromWKB Returns a SqlGeometry Point instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый методСтатический элемент STMPolyFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STMPolyFromWKB Returns a SqlGeometry MultiPolygon instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый метод STNumCurves Returns the number of curves in a one-dimensional SqlGeometry instance.
Открытый метод STNumGeometries Returns the number of SqlGeometry that comprise a SqlGeometry instance.
Открытый метод STNumInteriorRing Returns the number of interior rings of a Polygon SqlGeometry instance.
Открытый метод STNumPoints Returns the sum of the number of points in each of the figures in a SqlGeometry instance.
Открытый метод STOverlaps Determines whether the specified SqlGeometry overlaps the current SqlGeometry.
Открытый методСтатический элемент STPointFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STPointFromWKB Returns a SqlGeometry Point instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый метод STPointN Returns a specified point in a SqlGeometry instance.
Открытый метод STPointOnSurface Returns an arbitrary point located within the interior of a SqlGeometry instance.
Открытый методСтатический элемент STPolyFromText Returns a SqlGeometry instance from an Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation augmented with any Z (elevation) and M (measure) values carried by the instance.
Открытый методСтатический элемент STPolyFromWKB Returns a SqlGeometry Polygon instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.
Открытый метод STRelate Determines whether the calling SqlGeometry is related to the specified SqlGeometry.
Открытый метод STStartPoint Returns the start point of a SqlGeometry instance.
Открытый метод STSymDifference Returns an object that represents all points that are either in one SqlGeometry instance or another SqlGeometry instance, but not those points that lie in both instances.
Открытый метод STTouches Determines whether the specified SqlGeometry touches the current SqlGeometry.
Открытый метод STUnion Returns an object that represents the union of a SqlGeometry instance with another SqlGeometry instance.
Открытый метод STWithin Determines whether the current SqlGeometry is completely within the specified SqlGeometry instance.
Открытый метод ToString Returns the Open Geospatial Consortium (OGC) Well-Known Text (WKT) representation of a SqlGeometry instance augmented with any Z (elevation) and M (measure) values carried by the instance. (Переопределяет Object.ToString().)
Открытый метод Write Writes a SqlGeometry instance to a binary stream. SqlGeometry

В начало

Явные реализации интерфейса

  Имя Описание
Явная реализация интерфейсаЗакрытый метод ISqlSpatialGridIndexable.BufferForDistanceQuery Returns the buffer for distance query for the SQL Geometry.
Явная реализация интерфейсаЗакрытый метод ISqlSpatialGridIndexable.GetBoundingBoxCorners Returns a value for the bounding box corners for the SQL Geometry.
Явная реализация интерфейсаЗакрытый метод ISqlSpatialGridIndexable.GetGridCoverage Returns the grid coverage of the SQL Geometry.
Явная реализация интерфейсаЗакрытый метод ISqlSpatialGridIndexable.InteriorBufferForDistanceQuery Gets the interior buffer for distance query for the SQL Geometry.

В начало

Замечания

SQL Server 2012 supports a set of methods for the geometry spatial data type. These methods include methods on geometry that are defined by the Open Geospatial Consortium (OGC) standard and a set of Microsoft extensions to that standard.

Безопасность многопоточности

Любые открытые статический (Shared в Visual Basic) элементы этого типа потокобезопасны. Потокобезопасность с элементами экземпляров не гарантируется.

См. также

Справочник

Пространство имен Microsoft.SqlServer.Types