Expose way for native modules to modify JSC context

Reviewed By: svcscm

Differential Revision: D2933197

fb-gh-sync-id: 32eb943ab341804343bbcadd29f0377fccf75de6
shipit-source-id: 32eb943ab341804343bbcadd29f0377fccf75de6
This commit is contained in:
Scott Kyle
2016-02-15 12:58:29 -08:00
committed by facebook-github-bot-1
parent 46a8f1d8e0
commit e5ba46c30d
13 changed files with 77 additions and 2 deletions
@@ -87,4 +87,13 @@ public class ReactBridge extends Countable {
public native void stopProfiler(String title, String filename);
private native void handleMemoryPressureModerate();
private native void handleMemoryPressureCritical();
/**
* This method will return a long representing the underlying JSGlobalContextRef pointer or
* 0 (representing NULL) when in Chrome debug mode, and is only useful if passed back through
* the JNI to native code that will use it with the JavaScriptCore C API.
* **WARNING:** This method is *experimental* and should only be used when no other option is
* available. It will likely change in a future release!
*/
public native long getJavaScriptContextNativePtrExperimental();
}