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


SqlSpatialServices.Distance - метод (DbGeography, DbGeography)

[Эта страница относится к документации к Entity Framework 6. Последняя версия доступна в составе пакета Entity Framework NuGet. Дополнительные сведения об Entity Framework см. в разделе msdn.com/data/ef.]

Вычисляет расстояние между ближайшими точками двух значений DbGeography.

Пространство имен:  System.Data.Entity.SqlServer
Сборка:  EntityFramework.SqlServer (в EntityFramework.SqlServer.dll)

Синтаксис

'Декларация
Public Overrides Function Distance ( _
    geographyValue As DbGeography, _
    otherGeography As DbGeography _
) As Double
'Применение
Dim instance As SqlSpatialServices 
Dim geographyValue As DbGeography 
Dim otherGeography As DbGeography 
Dim returnValue As Double 

returnValue = instance.Distance(geographyValue, _
    otherGeography)
public override double Distance(
    DbGeography geographyValue,
    DbGeography otherGeography
)
public:
virtual double Distance(
    DbGeography^ geographyValue, 
    DbGeography^ otherGeography
) override
abstract Distance : 
        geographyValue:DbGeography * 
        otherGeography:DbGeography -> float  
override Distance : 
        geographyValue:DbGeography * 
        otherGeography:DbGeography -> float
public override function Distance(
    geographyValue : DbGeography, 
    otherGeography : DbGeography
) : double

Параметры

Возвращаемое значение

Тип: System.Double
Значение double, указывающее расстояние между двумя ближайшими точками значений geographyValue и otherGeography.

См. также

Справочник

SqlSpatialServices Класс

Distance - перегрузка

System.Data.Entity.SqlServer - пространство имен