共用方式為


SqlSpatialServices.Relate 方法

[此頁面專屬於 Entity Framework 第 6 版。最新版本可從 'Entity Framework' NuGet 套件取得。如需 Entity Framework 的詳細資訊,請參閱 msdn.com/data/ef。]

依據指定的維度延伸九交模型 (DE-9IM) 交集模式,判斷兩個指定的 DbGeometry 值是否在空間上有關聯。

命名空間:  System.Data.Entity.SqlServer
組件:  EntityFramework.SqlServer (在 EntityFramework.SqlServer.dll 中)

語法

'宣告
Public Overrides Function Relate ( _
    geometryValue As DbGeometry, _
    otherGeometry As DbGeometry, _
    matrix As String _
) As Boolean
'用途
Dim instance As SqlSpatialServices 
Dim geometryValue As DbGeometry 
Dim otherGeometry As DbGeometry 
Dim matrix As String 
Dim returnValue As Boolean 

returnValue = instance.Relate(geometryValue, _
    otherGeometry, matrix)
public override bool Relate(
    DbGeometry geometryValue,
    DbGeometry otherGeometry,
    string matrix
)
public:
virtual bool Relate(
    DbGeometry^ geometryValue, 
    DbGeometry^ otherGeometry, 
    String^ matrix
) override
abstract Relate : 
        geometryValue:DbGeometry * 
        otherGeometry:DbGeometry * 
        matrix:string -> bool  
override Relate : 
        geometryValue:DbGeometry * 
        otherGeometry:DbGeometry * 
        matrix:string -> bool
public override function Relate(
    geometryValue : DbGeometry, 
    otherGeometry : DbGeometry, 
    matrix : String
) : boolean

參數

  • matrix
    類型:System.String
    包含定義關聯性之 (DE-9IM) 交集模式文字表示的字串。

傳回值

類型:System.Boolean
若依指定的交集模式matrix,此 geometryValue 值和 otherGeometry 相關,則為 true,否則為 false。

請參閱

參考

SqlSpatialServices 類別

System.Data.Entity.SqlServer 命名空間