ResourceManagerStringLocalizerFactory.GetResourcePrefix 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| 名稱 | Description |
|---|---|
| GetResourcePrefix(TypeInfo) |
取得用來查詢資源的資源前綴。 |
| GetResourcePrefix(String, String) |
取得用來查詢資源的資源前綴。 |
| GetResourcePrefix(TypeInfo, String, String) |
取得用來查詢資源的資源前綴。 |
| GetResourcePrefix(String, String, String) |
取得用來查詢資源的資源前綴。 |
GetResourcePrefix(TypeInfo)
取得用來查詢資源的資源前綴。
protected:
virtual System::String ^ GetResourcePrefix(System::Reflection::TypeInfo ^ typeInfo);
protected virtual string GetResourcePrefix(System.Reflection.TypeInfo typeInfo);
abstract member GetResourcePrefix : System.Reflection.TypeInfo -> string
override this.GetResourcePrefix : System.Reflection.TypeInfo -> string
Protected Overridable Function GetResourcePrefix (typeInfo As TypeInfo) As String
參數
- typeInfo
- TypeInfo
需要查詢的資源類型。
傳回
資源查找的前綴。
適用於
GetResourcePrefix(String, String)
取得用來查詢資源的資源前綴。
protected:
virtual System::String ^ GetResourcePrefix(System::String ^ baseResourceName, System::String ^ baseNamespace);
protected virtual string GetResourcePrefix(string baseResourceName, string baseNamespace);
abstract member GetResourcePrefix : string * string -> string
override this.GetResourcePrefix : string * string -> string
Protected Overridable Function GetResourcePrefix (baseResourceName As String, baseNamespace As String) As String
參數
- baseResourceName
- String
要查詢的資源名稱
- baseNamespace
- String
應用程式的基礎命名空間。
傳回
資源查找的前綴。
適用於
GetResourcePrefix(TypeInfo, String, String)
取得用來查詢資源的資源前綴。
protected:
virtual System::String ^ GetResourcePrefix(System::Reflection::TypeInfo ^ typeInfo, System::String ^ baseNamespace, System::String ^ resourcesRelativePath);
protected virtual string GetResourcePrefix(System.Reflection.TypeInfo typeInfo, string? baseNamespace, string? resourcesRelativePath);
abstract member GetResourcePrefix : System.Reflection.TypeInfo * string * string -> string
override this.GetResourcePrefix : System.Reflection.TypeInfo * string * string -> string
Protected Overridable Function GetResourcePrefix (typeInfo As TypeInfo, baseNamespace As String, resourcesRelativePath As String) As String
參數
- typeInfo
- TypeInfo
需要查詢的資源類型。
- baseNamespace
- String
應用程式的基礎命名空間。
- resourcesRelativePath
- String
包含所有資源的資料夾。
傳回
資源查找的前綴。
備註
對於「Sample.Controllers.Home」這個類型,如果有 resourceRelativePath,如果沒有,回傳「Sample.Resourcepath.Controllers.Home」,就會回傳「Sample.Controllers.Home」。
適用於
GetResourcePrefix(String, String, String)
取得用來查詢資源的資源前綴。
protected:
virtual System::String ^ GetResourcePrefix(System::String ^ location, System::String ^ baseName, System::String ^ resourceLocation);
protected virtual string GetResourcePrefix(string location, string baseName, string resourceLocation);
abstract member GetResourcePrefix : string * string * string -> string
override this.GetResourcePrefix : string * string * string -> string
Protected Overridable Function GetResourcePrefix (location As String, baseName As String, resourceLocation As String) As String
參數
- location
- String
資源的大致位置。
- baseName
- String
資源的基礎名稱。
- resourceLocation
- String
資源在 location中的位置。
傳回
用來查詢資源的資源前綴。