Search completed in 0.89 seconds.
13 results for "addNamed":
JS::Add*Root
MozillaProjectsSpiderMonkeyJSAPI referenceJS::Add Root
syntax bool js::addvalueroot(jscontext *cx, js::heap<js::value> *vp); bool js::addstringroot(jscontext *cx, js::heap<jsstring *> *rp); bool js::addobjectroot(jscontext *cx, js::heap<jsobject *> *rp); bool js::addnamedvalueroot(jscontext *cx, js::heap<js::value> *vp, const char *name); bool js::addnamedvaluerootrt(jsruntime *rt, js::heap<js::value> *vp, const char *name); bool js::addnamedstringroot(jscontext *cx, js::heap<jsstring *> *rp, const char *name); bool js::addnamedobjectroot(jscontext *cx, js::heap<jsobject *> *rp, ...
... const char *name); bool js::addnamedscriptroot(jscontext *cx, js::heap<jsscript *> *rp, const char *name); name type description cx jscontext * the context in which to add the new root.
... an entry for rp is added to the garbage collector's root set for the jsruntime associated with cx (or, in js::addnamedvaluerootrt, the runtime rt).
...And 2 more matches
JS_Add*Root
MozillaProjectsSpiderMonkeyJSAPI referenceJS AddRoot
syntax jsbool js_addvalueroot(jscontext *cx, jsval *vp); jsbool js_addstringroot(jscontext *cx, jsstring **spp); jsbool js_addobjectroot(jscontext *cx, jsobject **opp); jsbool js_addgcthingroot(jscontext *cx, void **rp); jsbool js_addnamedvalueroot(jscontext *cx, jsval *vp, const char *name); jsbool js_addnamedstringroot(jscontext *cx, jsstring **spp, const char *name); jsbool js_addnamedobjectroot(jscontext *cx, jsobject **opp, const char *name); jsbool js_addnamedgcthingroot(jscontext *cx, void **rp, const char *name); name type description cx jscontext * the context in which to add the new root.
... vp jsval * (in js_addvalueroot and js_addnamedvalueroot) the address of the jsval variable to root spp jsstring ** (in js_addstringroot and js_addnamedstringroot) the address of the jsstring* variable to root opp jsobject ** (in js_addobjectroot and js_addnamedobjectroot) the address of the jsobject* variable to root rp void ** (in js_addgcthingroot and js_addnamedgcthingroot) the address of the jsstring* or jsobject* (not jsval) variable to root name const char * (in js_addnamedroot and js_addnamedrootrt) the name of the new root, or null.
... an entry for rp is added to the garbage collector's root set for the jsruntime associated with cx (or, in js_addnamedrootrt, the runtime rt).
...And 2 more matches
JS::Remove*Root
MozillaProjectsSpiderMonkeyJSAPI referenceJS::Remove Root
this must have been passed to one of js::addvalueroot, js::addnamedvalueroot or js::addnamedvaluerootrt.
...this must have been passed to either js::addstringroot or js::addnamedstringroot.
...this must have been passed to either js::addobjectroot or js::addnamedobjectroot.
...this must have been passed to js::addnamedscriptroot.
JS_Remove*Root
MozillaProjectsSpiderMonkeyJSAPI referenceJS RemoveRoot
this must have been passed to either js_addvalueroot or js_addnamedvalueroot.
... this must have been passed to either js_addstringroot or js_addnamedstringroot.
... this must have been passed to either js_addobjectroot or js_addnamedobjectroot.
... this must have been passed to either js_addgcthingroot or js_addnamedgcthingroot.
JSAPI reference
MozillaProjectsSpiderMonkeyJSAPI reference
class js::autoscriptvector added in spidermonkey 17 class js::handlevaluearray added in spidermonkey 31 js::add*root added in spidermonkey 31 obsolete since jsapi 38 js::addvalueroot added in spidermonkey 31 obsolete since jsapi 38 js::addstringroot added in spidermonkey 31 obsolete since jsapi 38 js::addobjectroot added in spidermonkey 31 obsolete since jsapi 38 js::addnamedvalueroot added in spidermonkey 31 obsolete since jsapi 38 js::addnamedvaluerootrt added in spidermonkey 31 obsolete since jsapi 38 js::addnamedscriptroot added in spidermonkey 31 obsolete since jsapi 38 js::addnamedstringroot added in spidermonkey 31 obsolete since jsapi 38 js::addnamedobjectroot added in spidermonkey 31 obsolete since jsapi 38 js::remove*root added in spidermon...
...bsolete since jsapi 38 js::removeobjectrootrt added in spidermonkey 31 obsolete since jsapi 38 js::removescriptrootrt added in spidermonkey 31 obsolete since jsapi 38 js_add*root obsolete since jsapi 31 js_addvalueroot obsolete since jsapi 31 js_addstringroot obsolete since jsapi 31 js_addobjectroot obsolete since jsapi 31 js_addgcthingroot obsolete since jsapi 31 js_addnamedvalueroot obsolete since jsapi 31 js_addnamedstringroot obsolete since jsapi 31 js_addnamedobjectroot obsolete since jsapi 31 js_addnamedgcthingroot obsolete since jsapi 31 js_remove*root obsolete since jsapi 31 js_removevalueroot obsolete since jsapi 31 js_removestringroot obsolete since jsapi 31 js_removeobjectroot obsolete since jsapi 31 js_removegcthingroot obsole...
...te since jsapi 31 js_addroot obsolete since javascript 1.8.5 js_addnamedroot obsolete since javascript 1.8.5 js_addnamedrootrt obsolete since javascript 1.8.5 js_removeroot obsolete since javascript 1.8.5 js_removerootrt obsolete since javascript 1.8.5 js_mapgcroots obsolete since jsapi 19 jsgcmaprootfun obsolete since jsapi 19 js_dumpnamedroots obsolete since jsapi 19 local root scopes were another way of protecting objects from the garbage collector.
SpiderMonkey 1.8.5
MozillaProjectsSpiderMonkeyReleases1.8.5
js_addroot has been replaced by js_addobjectroot, js_addvalueroot and js_addstringroot; similar changes were made for js_addnamedroot and js_removeroot.
...new c apis js_assert_string_is_flat js_addgcthingroot js_addnamedgcthingroot js_addnamedobjectroot js_addnamedstringroot js_addnamedvalueroot js_addobjectroot js_addstringroot js_addvalueroot js_alreadyhasownpropertybyid js_anchorptr js_beginjsonparse (removed in future releases, replaced with js_parsejson) js_compilefilehandleforprincipalsversion js_compilescriptforprincipalsversion js_compileucfunctionforprincipalsversion js_compileucscriptforpri...
... jsautorequest jsautosuspendrequest jsautocheckrequest jsautoentercompartment js::anchor<> js::call obsolete apis js_clearnewbornroots js_enterlocalrootscope js_leavelocalrootscope js_leavelocalrootscopewithresult js_forgetlocalroot js_newgrowablestring deleted apis js_addnamedroot – use js_add*root js_addnamedrootrt – use js_add*root js_addroot – use js_add*root js_clearnewbornroots – no longer needed js_clearoperationcallback js_clearregexproots js_decompilescript js_destroyscript js_enterlocalrootscope js_executescriptpart js_forgetlocalroot js_getfunctionname js_getoperationlimit js_getscriptobject js_getstringbytes js_getstringchars js_isass...
JSAPI User Guide
MozillaProjectsSpiderMonkeyJSAPI User Guide
in either case, if you create an object and then want it to persist in the run time where it can be used by other scripts, you must root the object by calling js_add*root or js_addnamed*root.
...*/ jsbool compileandrepeat(jscontext *cx, const char *filename) { jsscript *script; jsobject *scriptobj; script = js_compileutf8file(cx, js_getglobalobject(cx), filename); if (!script) return false; /* compilation error */ scriptobj = js_newscriptobject(cx, script); if (!scriptobj) { js_destroyscript(cx, script); return false; } if (!js_addnamedobjectroot(cx, &scriptobj, "compileandrepeat script object")) return false; for (;;) { jsval result; if (!js_executescript(cx, js_getglobalobject(cx), script, &result)) break; js_maybegc(cx); } js_removeobjectroot(cx, &scriptobj); /* scriptobj becomes unreachable and will eventually be collecte...
JS_DumpNamedRoots
MozillaProjectsSpiderMonkeyJSAPI referenceJS DumpNamedRoots
description each call to js_addnamedroot creates a record in a table of named roots maintained by the garbage collector.
...this is the pointer that the application passed to js_addnamedroot.
JS_RemoveRootRT
MozillaProjectsSpiderMonkeyJSAPI referenceJS RemoveRootRT
this must have been passed to one of js_addroot, js_addnamedroot, or js_addnamedrootrt earlier.
...see also mxr id search for js_removeroot jsval_is_gcthing js_addroot js_addnamedroot js_addnamedrootrt js_dumpnamedroots, js_removeroot ...
SpiderMonkey 1.8.7
MozillaProjectsSpiderMonkeyReleases1.8.7
js_addroot has been replaced by js_addobjectroot, js_addvalueroot and js_addstringroot; similar changes were made for js_addnamedroot and js_removeroot.
...new c apis js_assert_string_is_flat js_addgcthingroot js_addnamedgcthingroot js_addnamedobjectroot js_addnamedstringroot js_addnamedvalueroot js_addobjectroot js_addstringroot js_addvalueroot js_alreadyhasownpropertybyid js_anchorptr js_beginjsonparse (removed in future releases, replaced with js_parsejson) js_compilefilehandleforprincipalsversion js_compilescriptforprincipalsversion js_compileucfunctionforprincipalsversion js_compileucscriptforpri...
2006-11-17 - Archive of obsolete content
ArchiveNewsgroup summariesmozilla-dev-tech-js-engine2006-11-17
discussions js_addnamedroot a user is wondering where and when he would need to call js_addnamedroot in c code.
Index
MozillaProjectsSpiderMonkeyIndex
249 js_dumpnamedroots jsapi reference, obsolete, spidermonkey each call to js_addnamedroot creates a record in a table of named roots maintained by the garbage collector.
SpiderMonkey 38
MozillaProjectsSpiderMonkeyReleases38
deleted apis js::addnamedobjectroot (bug 1107639) js::addnamedscriptroot (bug 1107639) js::addnamedstringroot (bug 1107639) js::addnamedvalueroot (bug 1107639) js::addnamedvaluerootrt (bug 1107639) js::addobjectroot (bug 1107639) js::addstringroot (bug 1107639) js::addvalueroot (bug 1107639) js::removeobjectroot (bug 1107639) js::removeobjectrootrt (bug 1107639) js::removescriptroot (bug 1107639) js::removescri...