OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_ISOLATE_H_ | 5 #ifndef V8_ISOLATE_H_ |
6 #define V8_ISOLATE_H_ | 6 #define V8_ISOLATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <queue> | 9 #include <queue> |
10 #include <set> | 10 #include <set> |
(...skipping 760 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
771 void RequestInterrupt(InterruptCallback callback, void* data); | 771 void RequestInterrupt(InterruptCallback callback, void* data); |
772 void InvokeApiInterruptCallbacks(); | 772 void InvokeApiInterruptCallbacks(); |
773 | 773 |
774 // Administration | 774 // Administration |
775 void Iterate(ObjectVisitor* v); | 775 void Iterate(ObjectVisitor* v); |
776 void Iterate(ObjectVisitor* v, ThreadLocalTop* t); | 776 void Iterate(ObjectVisitor* v, ThreadLocalTop* t); |
777 char* Iterate(ObjectVisitor* v, char* t); | 777 char* Iterate(ObjectVisitor* v, char* t); |
778 void IterateThread(ThreadVisitor* v, char* t); | 778 void IterateThread(ThreadVisitor* v, char* t); |
779 | 779 |
780 // Returns the current native context. | 780 // Returns the current native context. |
781 Handle<Context> native_context(); | 781 inline Handle<Context> native_context(); |
| 782 inline Context* raw_native_context(); |
782 | 783 |
783 // Returns the native context of the calling JavaScript code. That | 784 // Returns the native context of the calling JavaScript code. That |
784 // is, the native context of the top-most JavaScript frame. | 785 // is, the native context of the top-most JavaScript frame. |
785 Handle<Context> GetCallingNativeContext(); | 786 Handle<Context> GetCallingNativeContext(); |
786 | 787 |
787 void RegisterTryCatchHandler(v8::TryCatch* that); | 788 void RegisterTryCatchHandler(v8::TryCatch* that); |
788 void UnregisterTryCatchHandler(v8::TryCatch* that); | 789 void UnregisterTryCatchHandler(v8::TryCatch* that); |
789 | 790 |
790 char* ArchiveThread(char* to); | 791 char* ArchiveThread(char* to); |
791 char* RestoreThread(char* from); | 792 char* RestoreThread(char* from); |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1072 | 1073 |
1073 // Get (and lazily initialize) the registry for per-isolate symbols. | 1074 // Get (and lazily initialize) the registry for per-isolate symbols. |
1074 Handle<JSObject> GetSymbolRegistry(); | 1075 Handle<JSObject> GetSymbolRegistry(); |
1075 | 1076 |
1076 void AddCallCompletedCallback(CallCompletedCallback callback); | 1077 void AddCallCompletedCallback(CallCompletedCallback callback); |
1077 void RemoveCallCompletedCallback(CallCompletedCallback callback); | 1078 void RemoveCallCompletedCallback(CallCompletedCallback callback); |
1078 void FireCallCompletedCallback(); | 1079 void FireCallCompletedCallback(); |
1079 | 1080 |
1080 void AddBeforeCallEnteredCallback(BeforeCallEnteredCallback callback); | 1081 void AddBeforeCallEnteredCallback(BeforeCallEnteredCallback callback); |
1081 void RemoveBeforeCallEnteredCallback(BeforeCallEnteredCallback callback); | 1082 void RemoveBeforeCallEnteredCallback(BeforeCallEnteredCallback callback); |
1082 void FireBeforeCallEnteredCallback(); | 1083 inline void FireBeforeCallEnteredCallback(); |
1083 | 1084 |
1084 void AddMicrotasksCompletedCallback(MicrotasksCompletedCallback callback); | 1085 void AddMicrotasksCompletedCallback(MicrotasksCompletedCallback callback); |
1085 void RemoveMicrotasksCompletedCallback(MicrotasksCompletedCallback callback); | 1086 void RemoveMicrotasksCompletedCallback(MicrotasksCompletedCallback callback); |
1086 void FireMicrotasksCompletedCallback(); | 1087 void FireMicrotasksCompletedCallback(); |
1087 | 1088 |
1088 void SetPromiseRejectCallback(PromiseRejectCallback callback); | 1089 void SetPromiseRejectCallback(PromiseRejectCallback callback); |
1089 void ReportPromiseReject(Handle<JSObject> promise, Handle<Object> value, | 1090 void ReportPromiseReject(Handle<JSObject> promise, Handle<Object> value, |
1090 v8::PromiseRejectEvent event); | 1091 v8::PromiseRejectEvent event); |
1091 | 1092 |
1092 void EnqueueMicrotask(Handle<Object> microtask); | 1093 void EnqueueMicrotask(Handle<Object> microtask); |
(...skipping 549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1642 | 1643 |
1643 EmbeddedVector<char, 128> filename_; | 1644 EmbeddedVector<char, 128> filename_; |
1644 FILE* file_; | 1645 FILE* file_; |
1645 int scope_depth_; | 1646 int scope_depth_; |
1646 }; | 1647 }; |
1647 | 1648 |
1648 } // namespace internal | 1649 } // namespace internal |
1649 } // namespace v8 | 1650 } // namespace v8 |
1650 | 1651 |
1651 #endif // V8_ISOLATE_H_ | 1652 #endif // V8_ISOLATE_H_ |
OLD | NEW |