NSObject.ObserveValue(NSString, NSObject, NSDictionary, IntPtr) 方法

定义

指示相对于此对象的指定 keyPath 处的值已更改。

[Foundation.Export("observeValueForKeyPath:ofObject:change:context:")]
public virtual void ObserveValue (Foundation.NSString keyPath, Foundation.NSObject ofObject, Foundation.NSDictionary change, IntPtr context);
abstract member ObserveValue : Foundation.NSString * Foundation.NSObject * Foundation.NSDictionary * nativeint -> unit
override this.ObserveValue : Foundation.NSString * Foundation.NSObject * Foundation.NSDictionary * nativeint -> unit

参数

keyPath
NSString

用于执行值查找的键路径。 键路径由一系列小写 ASCII 字符串组成,其中没有空格,以点字符分隔。

ofObject
NSObject
change
NSDictionary
context
IntPtr

nativeint

属性

注解

如果已使用 方法注册了观察程序,则会调用此方法AddObserver(NSObject, String, NSKeyValueObservingOptions, IntPtr)

适用于