次の方法で共有


UserNotificationChangedTrigger クラス

定義

UserNotification が追加または削除されたときに発生するトリガーを表します。

public ref class UserNotificationChangedTrigger sealed : IBackgroundTrigger
/// [Windows.Foundation.Metadata.Activatable(Windows.ApplicationModel.Background.IUserNotificationChangedTriggerFactory, 196608, "Windows.Foundation.UniversalApiContract")]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 196608)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
class UserNotificationChangedTrigger final : IBackgroundTrigger
/// [Windows.Foundation.Metadata.Activatable(Windows.ApplicationModel.Background.IUserNotificationChangedTriggerFactory, 196608, "Windows.Foundation.UniversalApiContract")]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 196608)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class UserNotificationChangedTrigger final : IBackgroundTrigger
[Windows.Foundation.Metadata.Activatable(typeof(Windows.ApplicationModel.Background.IUserNotificationChangedTriggerFactory), 196608, "Windows.Foundation.UniversalApiContract")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 196608)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
public sealed class UserNotificationChangedTrigger : IBackgroundTrigger
[Windows.Foundation.Metadata.Activatable(typeof(Windows.ApplicationModel.Background.IUserNotificationChangedTriggerFactory), 196608, "Windows.Foundation.UniversalApiContract")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 196608)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class UserNotificationChangedTrigger : IBackgroundTrigger
function UserNotificationChangedTrigger(notificationKinds)
Public NotInheritable Class UserNotificationChangedTrigger
Implements IBackgroundTrigger
継承
Object Platform::Object IInspectable UserNotificationChangedTrigger
属性
実装

Windows の要件

デバイス ファミリ
Windows 10 Anniversary Edition (10.0.14393.0 で導入)
API contract
Windows.Foundation.UniversalApiContract (v3.0 で導入)

注釈

ユーザー通知リスナーでは、明示的なユーザーアクセス許可を使用する前に付与する必要があります。 通知にアクセスする前に、UI スレッドから BackgroundExecutionManager.RequestAccessAsync を呼び出します。

コンストラクター

UserNotificationChangedTrigger(NotificationKinds)

UserNotificationChangedTrigger クラスの新しいインスタンスを初期化します。

適用対象

こちらもご覧ください