OLD | NEW |
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2007-2008 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 2228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2239 Handle<ObjectTemplate> global_template = Handle<ObjectTemplate>(), | 2239 Handle<ObjectTemplate> global_template = Handle<ObjectTemplate>(), |
2240 Handle<Value> global_object = Handle<Value>()); | 2240 Handle<Value> global_object = Handle<Value>()); |
2241 | 2241 |
2242 /** Returns the last entered context. */ | 2242 /** Returns the last entered context. */ |
2243 static Local<Context> GetEntered(); | 2243 static Local<Context> GetEntered(); |
2244 | 2244 |
2245 /** Returns the context that is on the top of the stack. */ | 2245 /** Returns the context that is on the top of the stack. */ |
2246 static Local<Context> GetCurrent(); | 2246 static Local<Context> GetCurrent(); |
2247 | 2247 |
2248 /** | 2248 /** |
| 2249 * Returns the context of the calling JavaScript code. That is the |
| 2250 * context of the top-most JavaScript frame. If there are no |
| 2251 * JavaScript frames an empty handle is returned. |
| 2252 */ |
| 2253 static Local<Context> GetCalling(); |
| 2254 |
| 2255 /** |
2249 * Sets the security token for the context. To access an object in | 2256 * Sets the security token for the context. To access an object in |
2250 * another context, the security tokens must match. | 2257 * another context, the security tokens must match. |
2251 */ | 2258 */ |
2252 void SetSecurityToken(Handle<Value> token); | 2259 void SetSecurityToken(Handle<Value> token); |
2253 | 2260 |
2254 /** Restores the security token to the default value. */ | 2261 /** Restores the security token to the default value. */ |
2255 void UseDefaultSecurityToken(); | 2262 void UseDefaultSecurityToken(); |
2256 | 2263 |
2257 /** Returns the security token of this context.*/ | 2264 /** Returns the security token of this context.*/ |
2258 Handle<Value> GetSecurityToken(); | 2265 Handle<Value> GetSecurityToken(); |
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2592 | 2599 |
2593 } // namespace v8 | 2600 } // namespace v8 |
2594 | 2601 |
2595 | 2602 |
2596 #undef V8EXPORT | 2603 #undef V8EXPORT |
2597 #undef V8EXPORT_INLINE | 2604 #undef V8EXPORT_INLINE |
2598 #undef TYPE_CHECK | 2605 #undef TYPE_CHECK |
2599 | 2606 |
2600 | 2607 |
2601 #endif // V8_H_ | 2608 #endif // V8_H_ |
OLD | NEW |