SourceLocation 類別

定義

識別目標原始碼檔案中的特定位置。

public ref class SourceLocation
[System.Serializable]
public class SourceLocation
[<System.Serializable>]
type SourceLocation = class
Public Class SourceLocation
繼承
SourceLocation
屬性

建構函式

名稱 Description
SourceLocation(String, Int32, Int32, Int32, Int32)

建立一個新的類別實例 SourceLocation ,指定原始碼檔案名稱及該檔案中資料範圍的參數。

SourceLocation(String, Int32)

建立一個新的類別實例 SourceLocation ,指定原始碼檔名及該檔案中行數。

屬性

名稱 Description
EndColumn

取得原始碼檔案中一個或多個欄位的最後一欄。

EndLine

在原始碼檔案中取得一行或多行的最後一行。

FileName

取得目標原始碼檔案的名稱。

IsSingleWholeLine

會取得一個值,指示原始碼檔案中行與欄設定是否定義的是單一完整行,而非多行。

StartColumn

取得原始碼檔案中一個或多個欄位的第一欄。

StartLine

在原始碼檔案中取得一行或多行的開場。

方法

名稱 Description
Equals(Object)

回傳一個值,表示該物件參考 SourceLocation 的原始碼檔案行與欄設定是否與另一個指定 SourceLocation 物件中的行與欄設定完全一致。

GetHashCode()

回傳一個唯一值來代表該 SourceLocation 物件。

GetType()

取得目前實例的 Type

(繼承來源 Object)
MemberwiseClone()

建立目前 Object的淺層複本。

(繼承來源 Object)
ToString()

傳回表示目前 物件的字串。

(繼承來源 Object)

適用於