Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(316)

Unified Diff: include/v8.h

Issue 7366: Split window support from V8. ... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 12 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/api.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
===================================================================
--- include/v8.h (revision 539)
+++ include/v8.h (working copy)
@@ -1052,6 +1052,12 @@
/** Tests for an index lookup interceptor.*/
bool HasIndexedLookupInterceptor();
+ /**
+ * Turns on access check on the object if the object is an instance of
+ * a template that has access check callbacks. If an object has no
+ * access check info, the object cannot be accessed by anyone.
+ */
+ void TurnOnAccessCheck();
static Local<Object> New();
static Object* Cast(Value* obj);
@@ -1609,10 +1615,15 @@
* When accessing properties on instances of this object template,
* the access check callback will be called to determine whether or
* not to allow cross-context access to the properties.
+ * The last parameter specifies whether access checks are turned
+ * on by default on instances. If access checks are off by default,
+ * they can be turned on on individual instances by calling
+ * Object::TurnOnAccessCheck().
*/
void SetAccessCheckCallbacks(NamedSecurityCallback named_handler,
IndexedSecurityCallback indexed_handler,
- Handle<Value> data = Handle<Value>());
+ Handle<Value> data = Handle<Value>(),
+ bool turned_on_by_default = true);
/**
* Gets the number of internal fields for objects generated from
@@ -2044,8 +2055,15 @@
*/
class EXPORT Context {
public:
+ /** Returns the global object of the context. */
Local<Object> Global();
+ /**
+ * Detaches the global object from its context before
+ * the global object can be reused to create a new context.
+ */
+ void DetachGlobal();
+
/** Creates a new context. */
static Persistent<Context> New(
ExtensionConfiguration* extensions = 0,
@@ -2058,15 +2076,15 @@
/** Returns the context that is on the top of the stack. */
static Local<Context> GetCurrent();
- /** Returns the security context that is currently used. */
- static Local<Context> GetCurrentSecurityContext();
-
/**
* Sets the security token for the context. To access an object in
* another context, the security tokens must match.
*/
void SetSecurityToken(Handle<Value> token);
+ /** Restores the security token to the default value. */
+ void UseDefaultSecurityToken();
+
/** Returns the security token of this context.*/
Handle<Value> GetSecurityToken();
@@ -2090,9 +2108,6 @@
/** Returns true if V8 has a current context. */
static bool InContext();
- /** Returns true if V8 has a current security context. */
- static bool InSecurityContext();
-
/**
* Stack-allocated class which sets the execution context for all
* operations executed within a local scope.
« no previous file with comments | « no previous file | src/api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698