newScriptingObjectOfClass method
ObjCObjectBase?
newScriptingObjectOfClass(
- ObjCObjectBase objectClass, {
- required NSString forValueForKey,
- ObjCObjectBase? withContentsValue,
- required NSDictionary properties,
newScriptingObjectOfClass:forValueForKey:withContentsValue:properties:
Implementation
objc.ObjCObjectBase? newScriptingObjectOfClass(
objc.ObjCObjectBase objectClass, {
required objc.NSString forValueForKey,
objc.ObjCObjectBase? withContentsValue,
required objc.NSDictionary properties,
}) {
objc.checkOsVersionInternal(
'NSObject.newScriptingObjectOfClass:forValueForKey:withContentsValue:properties:',
iOS: (true, null),
macOS: (false, (10, 5, 0)),
);
final _ret = _objc_msgSend_s92gih(
this.ref.pointer,
_sel_newScriptingObjectOfClass_forValueForKey_withContentsValue_properties_,
objectClass.ref.pointer,
forValueForKey.ref.pointer,
withContentsValue?.ref.pointer ?? ffi.nullptr,
properties.ref.pointer,
);
return _ret.address == 0
? null
: objc.ObjCObjectBase(_ret, retain: false, release: true);
}