LicenseContext.GetSavedLicenseKey(Type, Assembly) 方法

定義

在衍生類別中覆寫時,從指定的資源組件 (Assembly) 傳回指定型別的已儲存授權識別碼。

public:
 virtual System::String ^ GetSavedLicenseKey(Type ^ type, System::Reflection::Assembly ^ resourceAssembly);
public virtual string GetSavedLicenseKey (Type type, System.Reflection.Assembly resourceAssembly);
public virtual string? GetSavedLicenseKey (Type type, System.Reflection.Assembly? resourceAssembly);
abstract member GetSavedLicenseKey : Type * System.Reflection.Assembly -> string
override this.GetSavedLicenseKey : Type * System.Reflection.Assembly -> string
Public Overridable Function GetSavedLicenseKey (type As Type, resourceAssembly As Assembly) As String

參數

type
Type

Type,表示元件的型別。

resourceAssembly
Assembly

具有授權識別碼的 Assembly

傳回

指定型別的 LicenseKey。 除非您加以覆寫,否則這個方法會傳回 null

給繼承者的注意事項

覆寫此方法和 SetSavedLicenseKey(Type, String) 方法來實作已儲存的授權密鑰。 resourceAssembly如果 參數為 null,則您可以從主要執行 Assembly中擷取資源。

適用於

另請參閱