public static unsafe bool SetProperty( JSContextPtr cx, JSHandleObject obj, string name, JSHandleValue vp ) { fixed(char *pName = name) return(SetUCProperty(cx, obj, (IntPtr)pName, (uint)name.Length, vp)); }
public static JSHandleObject FromValue(Rooted <JS.Value> rval) { // Assert that we can actually convert the value into an object pointer. var ptr = rval.Value.AsObject; // Now get a handle to the value JSHandleValue v = rval; // HACK: Now take the value handle and turn it into an object handle. // This is valid because JS.Value type tagging is at the end of the 8 bytes. return(new JSHandleObject(v.AddressOfTarget)); }
public bool SetProperty(JSContextPtr context, string name, JSHandleValue value) { return(JSAPI.SetProperty(context, TransientSelf(), name, value)); }