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


Класс SqlGeometryBuilder

Constructs instances of SqlGeometry objects by using IGeometrySink interface.

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

System.Object
  Microsoft.SqlServer.Types.SqlGeometryBuilder

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

Синтаксис

'Декларация
<CLSCompliantAttribute(True)> _
Public Class SqlGeometryBuilder _
    Implements IGeometrySink110, IGeometrySink
'Применение
Dim instance As SqlGeometryBuilder
[CLSCompliantAttribute(true)]
public class SqlGeometryBuilder : IGeometrySink110, 
    IGeometrySink
[CLSCompliantAttribute(true)]
public ref class SqlGeometryBuilder : IGeometrySink110, 
    IGeometrySink
[<CLSCompliantAttribute(true)>]
type SqlGeometryBuilder =  
    class 
        interface IGeometrySink110 
        interface IGeometrySink 
    end
public class SqlGeometryBuilder implements IGeometrySink110, IGeometrySink

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

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

  Имя Описание
Открытый метод SqlGeometryBuilder Constructs a SqlGeometryBuilder object.

В начало

Свойства

  Имя Описание
Открытое свойство ConstructedGeometry Retrieves constructed spatial geometry object.

В начало

Методы

  Имя Описание
Открытый метод AddCircularArc(Double, Double, Double, Double) Adds a circular arc to the path.
Открытый метод AddCircularArc(Double, Double, Nullable<Double>, Nullable<Double>, Double, Double, Nullable<Double>, Nullable<Double>) Adds a circular arc to the path.
Открытый метод AddLine(Double, Double) Constructs additional points in a geometry type figure.
Открытый метод AddLine(Double, Double, Nullable<Double>, Nullable<Double>) Constructs additional points in the call sequence for a geometry type.
Открытый метод BeginFigure(Double, Double) Starts the call sequence for a geometry figure.
Открытый метод BeginFigure(Double, Double, Nullable<Double>, Nullable<Double>) Starts the call sequence for a geometry figure.
Открытый метод BeginGeometry Initializes a call sequence for a geometry type.
Открытый метод EndFigure Finishes a call sequence for a geometry figure.
Открытый метод EndGeometry Finishes a call sequence for a geometry type.
Открытый метод Equals (Производный от Object.)
Защищенный метод Finalize (Производный от Object.)
Открытый метод GetHashCode (Производный от Object.)
Открытый метод GetType (Производный от Object.)
Защищенный метод MemberwiseClone (Производный от Object.)
Открытый метод SetSrid Sets the Spatial Reference Identifier (SRID) for a geometry type call sequence.
Открытый метод ToString (Производный от Object.)

В начало

Замечания

Throws FormatException for an invalid call sequence or when a call sequence is incomplete when ConstructedGeometry() is invoked.

Примеры

The following example constructs a SqlGeometry object from a MultiLineString.

SqlGeometryBuilder b = new SqlGeometryBuilder();

b.SetSrid(0);

b.BeginGeometry(OpenGisGeometryType.MultiLineString);

b.BeginGeometry(OpenGisGeometryType.LineString);

b.BeginFigure(1, 1);

b.AddLine(3, 4);

b.EndFigure();

b.EndGeometry();

b.BeginGeometry(OpenGisGeometryType.LineString);

b.BeginFigure(-5, -3);

b.AddLine(2, 2);

b.EndFigure();

b.EndGeometry();

b.EndGeometry();

SqlGeometry g = b.ConstructedGeometry();

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

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

См. также

Справочник

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