OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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_INSPECTOR_V8STACKTRACEIMPL_H_ | 5 #ifndef V8_INSPECTOR_V8STACKTRACEIMPL_H_ |
6 #define V8_INSPECTOR_V8STACKTRACEIMPL_H_ | 6 #define V8_INSPECTOR_V8STACKTRACEIMPL_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 public: | 90 public: |
91 static std::shared_ptr<AsyncStackTrace> capture(V8Debugger*, | 91 static std::shared_ptr<AsyncStackTrace> capture(V8Debugger*, |
92 int contextGroupId, | 92 int contextGroupId, |
93 const String16& description, | 93 const String16& description, |
94 int maxStackSize); | 94 int maxStackSize); |
95 | 95 |
96 std::unique_ptr<protocol::Runtime::StackTrace> buildInspectorObject( | 96 std::unique_ptr<protocol::Runtime::StackTrace> buildInspectorObject( |
97 AsyncStackTrace* asyncCreation, int maxAsyncDepth) const; | 97 AsyncStackTrace* asyncCreation, int maxAsyncDepth) const; |
98 | 98 |
99 int contextGroupId() const; | 99 int contextGroupId() const; |
| 100 const String16& description() const; |
100 std::weak_ptr<AsyncStackTrace> parent() const; | 101 std::weak_ptr<AsyncStackTrace> parent() const; |
101 std::weak_ptr<AsyncStackTrace> creation() const; | 102 std::weak_ptr<AsyncStackTrace> creation() const; |
102 bool isEmpty() const; | 103 bool isEmpty() const; |
103 | 104 |
104 private: | 105 private: |
105 AsyncStackTrace(int contextGroupId, const String16& description, | 106 AsyncStackTrace(int contextGroupId, const String16& description, |
106 std::vector<std::shared_ptr<StackFrame>> frames, | 107 std::vector<std::shared_ptr<StackFrame>> frames, |
107 std::shared_ptr<AsyncStackTrace> asyncParent, | 108 std::shared_ptr<AsyncStackTrace> asyncParent, |
108 std::shared_ptr<AsyncStackTrace> asyncCreation); | 109 std::shared_ptr<AsyncStackTrace> asyncCreation); |
109 | 110 |
110 int m_contextGroupId; | 111 int m_contextGroupId; |
111 String16 m_description; | 112 String16 m_description; |
112 | 113 |
113 std::vector<std::shared_ptr<StackFrame>> m_frames; | 114 std::vector<std::shared_ptr<StackFrame>> m_frames; |
114 std::weak_ptr<AsyncStackTrace> m_asyncParent; | 115 std::weak_ptr<AsyncStackTrace> m_asyncParent; |
115 std::weak_ptr<AsyncStackTrace> m_asyncCreation; | 116 std::weak_ptr<AsyncStackTrace> m_asyncCreation; |
116 | 117 |
117 DISALLOW_COPY_AND_ASSIGN(AsyncStackTrace); | 118 DISALLOW_COPY_AND_ASSIGN(AsyncStackTrace); |
118 }; | 119 }; |
119 | 120 |
120 } // namespace v8_inspector | 121 } // namespace v8_inspector |
121 | 122 |
122 #endif // V8_INSPECTOR_V8STACKTRACEIMPL_H_ | 123 #endif // V8_INSPECTOR_V8STACKTRACEIMPL_H_ |
OLD | NEW |