共用方式為


ConnectedServiceHandlerHelper.TokenReplacementValues 屬性

定義

取得令牌取代索引鍵和值的字典,這些索引鍵和值將用來取代 AddFileAsync 和 PerformTokenReplacement 中的令牌。

public:
 abstract property System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ TokenReplacementValues { System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ get(); };
public abstract System.Collections.Generic.IDictionary<string,string> TokenReplacementValues { get; }
member this.TokenReplacementValues : System.Collections.Generic.IDictionary<string, string>
Public MustOverride ReadOnly Property TokenReplacementValues As IDictionary(Of String, String)

屬性值

傳回 IDictionary<TKey, TValue>

備註

令牌會以下列格式指定檔案內容:$TokenName$。 也就是說,令牌的名稱會緊接在 $ 字元之前和之後。

下列清單描述可使用的內建令牌:1。 ProjectName - 目前 VS 項目的名稱。 2. vslcid - 目前 UI 文化特性的地區設定識別碼,例如 - 適用於英文-美國0x1033。 3. RootNamespace - AddFileAsync 中新增之目前檔案的根命名空間。 對於 C# 專案,此值會根據 VS 專案的 DefaultNamespace 動態計算,再加上檔案要加入的資料夾。 對於 VB 專案,它只是 VS 專案的 DefaultNamespace。 4. ProjectDefaultNamespace - VS Project 的 “DefaultNamespace” 值,如專案屬性中所設定。 5. AssemblyName - VS Project 的輸出元件名稱。 6. ServiceInstance.Name - ConnectedServiceInstance 的名稱。 7. ServiceInstance.InstanceId - ConnectedServiceInstance 的 InstanceId。 8. 針對 ConnectedServiceInstance.Metadata 字典中的每個字串值,其名稱為 ServiceInstance 的標記。{元數據名稱} 將會加上元數據字典中對應 Value 的值。

適用於