getProperty method
Tests whether an object has a given property.
propertyName
(JSStringRef) A JSString containing the property's name.
exception
(JSValueRef*) A pointer to a JSValueRef in which to store an exception, if any. Pass NULL if you do not care to store an exception.
Implementation
JSValue getProperty(
String propertyName, {
JSValuePointer? exception,
}) {
return JSValue(
context,
JSObjectRef.jSObjectGetProperty(
context.pointer,
pointer,
JSString.fromString(propertyName).pointer,
(exception ?? JSValuePointer(nullptr)).pointer));
}