https://bitbucket.org/chromiumembedded/cef/wiki/JavaScriptIntegration#markdown-header-working-with-contexts
A.) The upper section says...
V8 will be inside a context if the current code location has a CefV8Handler, CefV8Accessor or OnContextCreated()/OnContextReleased() callback higher in the call stack.
How can the code determine - if i don't know it anyway during programming - , if it's executed inside a V8-context,
meaning, that there is a CefV8Handler, CefV8Accessor or OnContextCreated()/OnContextReleased() callback higher in the call stack?
B.) Moreover, the upper section says...
Arrays, objects and functions may only be created, modified and, in the case of functions, executed, if V8 is inside a context. If V8 is not inside a context then the application needs to enter a context by calling Enter() and exit the context by calling Exit(). The Enter() and Exit() methods should only be used:
1.)When creating a V8 object, function or array outside of an existing context. For example, when creating a JS object in response to a native menu callback.
2.)When creating a V8 object, function or array in a context other than the current context. For example, if a call originating from frame1 needs to modify the context of frame2.
In my comprehension, the first thing is again, knowing if V8 is inside a context, AND if it is 'theRightContext'.
In case i am already in a context, AND it is theRightOne, THEN i should NOT call Enter() and Exit().
In case i am already in a context, BUT it is NOT theRightOne, i have to call theRightContext->Enter() and theRightContext->Exit().
AND of course In case i am NOT YET in a context i also have to call theRightContext->Enter() and theRightContext->Exit(), right?
C.)
"Arrays, objects and functions may only be created, modified and, in the case of functions, executed, if V8 is inside a context."
I understand this sentence as: if i want to perform a javascript-context-operation of any kind, right ?...
D.) There is no difference in what you can do using ExecuteFunction (A) and ExecuteFunctionWithContext (B),
except using B lets you choose the context upon which the operation gets performed, right?