<see> (C# 程式設計手冊)
更新:2007 年 11 月
<see cref="member"/>
參數
- cref = "member"
對可以從目前編譯環境呼叫的成員或欄位的參考。編譯器會檢查特定程式碼項目是否存在,並將 member 傳遞給輸出 XML 中的項目名稱。member 需用雙引號 (" ") 括住。
備註
<see> 標記讓您指定文字中的連結。使用 <seealso> 可以指定要放置於 [請參閱] 區段的文字。
使用 /doc 進行編譯,將文件註解處理為檔案。
請參閱 <summary> 中使用 <see> 的範例。
範例
下列程式碼範例示範如何建立泛型型別的 cref 參考。
// compile with: /doc:DocFileName.xml
// the following cref shows how to specify the reference, such that,
// the compiler will resolve the reference
/// <summary cref="C{T}">
/// </summary>
class A { }
// the following cref shows another way to specify the reference,
// such that, the compiler will resolve the reference
// <summary cref="C < T >">
// the following cref shows how to hard-code the reference
/// <summary cref="T:C`1">
/// </summary>
class B { }
/// <summary cref="A">
/// </summary>
/// <typeparam name="T"></typeparam>
class C<T> { }