StoreAppLicense 類別

定義

提供目前應用程式的授權資訊,包括應用程式所提供產品的授權。

public ref class StoreAppLicense sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Services.Store.StoreContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class StoreAppLicense final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Services.Store.StoreContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class StoreAppLicense
Public NotInheritable Class StoreAppLicense
繼承
Object Platform::Object IInspectable StoreAppLicense
屬性

Windows 需求

裝置系列
Windows 10 Anniversary Edition (已於 10.0.14393.0 引進)
API contract
Windows.Services.Store.StoreContract (已於 v1.0 引進)

備註

StoreCoNtext.GetAppLicenseAsync方法會傳回此類型的物件。

版本歷程記錄

Windows 版本 SDK 版本 已新增值
1809 17763 IsDiscLicense

屬性

AddOnLicenses

取得使用者有權使用之長期附加元件的授權集合。 此屬性不包含消費性附加元件的授權。

ExpirationDate

取得應用程式授權的到期日期和時間。

ExtendedJsonData

取得 JSON 格式的完整授權資料。

IsActive

取得值,指出授權是否有效,並提供目前使用者使用應用程式的權利。

IsDiscLicense

取得值,這個值表示是否從以磁片為基礎的安裝取得目前的授權。

IsTrial

取得值,這個值表示授權是否為試用版授權。

IsTrialOwnedByThisUser

取得值,這個值表示目前使用者是否具有與此應用程式授權相關聯的使用限制試用版權利。

SkuStoreId

從 Microsoft Store 目錄取得授權應用程式 SKU 的市集識別碼。

TrialTimeRemaining

取得與此應用程式授權相關聯的使用限制試用版剩餘時間。

TrialUniqueId

取得唯一識別碼,識別目前使用者與與此應用程式授權相關聯的有限試用版組合。

適用於