共用方式為


NSObject.ChangeNotificationIsPriorKey 屬性

定義

ChangeNotificati 的通知常數

[Foundation.Field("NSKeyValueChangeNotificationIsPriorKey", "Foundation")]
public static Foundation.NSString ChangeNotificationIsPriorKey { get; }
member this.ChangeNotificationIsPriorKey : Foundation.NSString

屬性值

NSString 常數應作為 NSNotificationCenter 的權杖使用。

屬性

備註

這個常數可以與 搭配 NSNotificationCenter 使用,以註冊此通知的接聽程式。

// Lambda style
NSNotificationCenter.DefaultCenter.AddObserver (NSObject.ChangeNotificationIsPriorKey, (notification) => Console.WriteLine ("Received the notification NSObject", notification);

// Method style
void Callback (NSNotification notification)
{
    Console.WriteLine ("Received a notification NSObject", notification);
}
void Setup ()
{
    NSNotificationCenter.DefaultCenter.AddObserver (NSObject.ChangeNotificationIsPriorKey, Callback);
}

適用於