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

Side by Side Diff: third_party/WebKit/Source/platform/v8_inspector/public/V8StackTrace.h

Issue 2035653006: [DevTools] Move Console to v8 inspector. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: improved api a bit Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium 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 V8StackTrace_h 5 #ifndef V8StackTrace_h
6 #define V8StackTrace_h 6 #define V8StackTrace_h
7 7
8 #include "platform/inspector_protocol/Platform.h" 8 #include "platform/inspector_protocol/Platform.h"
9 #include "platform/inspector_protocol/String16.h" 9 #include "platform/inspector_protocol/String16.h"
10 #include "platform/v8_inspector/protocol/Runtime.h" 10 #include "platform/v8_inspector/protocol/Runtime.h"
11 11
12 #include <v8.h> 12 #include <v8.h>
13 13
14 namespace blink { 14 namespace blink {
15 15
16 class TracedValue; 16 // TODO(dgozman): migrate to V8SourceLocation.
17
18 const v8::StackTrace::StackTraceOptions stackTraceOptions = static_cast<v8::Stac kTrace::StackTraceOptions>(
19 v8::StackTrace::kLineNumber |
20 v8::StackTrace::kColumnOffset |
21 v8::StackTrace::kScriptId |
22 v8::StackTrace::kScriptNameOrSourceURL |
23 v8::StackTrace::kFunctionName);
24
25 class V8StackTrace { 17 class V8StackTrace {
26 public: 18 public:
27 static const size_t maxCallStackSizeToCapture = 200;
28
29 virtual bool isEmpty() const = 0; 19 virtual bool isEmpty() const = 0;
30 virtual String16 topSourceURL() const = 0; 20 virtual String16 topSourceURL() const = 0;
31 virtual int topLineNumber() const = 0; 21 virtual int topLineNumber() const = 0;
32 virtual int topColumnNumber() const = 0; 22 virtual int topColumnNumber() const = 0;
33 virtual String16 topScriptId() const = 0; 23 virtual String16 topScriptId() const = 0;
34 virtual String16 topFunctionName() const = 0; 24 virtual String16 topFunctionName() const = 0;
35 25
36 virtual ~V8StackTrace() { } 26 virtual ~V8StackTrace() { }
37 virtual std::unique_ptr<protocol::Runtime::StackTrace> buildInspectorObject( ) const = 0; 27 virtual std::unique_ptr<protocol::Runtime::StackTrace> buildInspectorObject( ) const = 0;
38 virtual String16 toString() const = 0; 28 virtual String16 toString() const = 0;
39 virtual std::unique_ptr<V8StackTrace> clone() = 0; 29 virtual std::unique_ptr<V8StackTrace> clone() = 0;
40 virtual std::unique_ptr<V8StackTrace> isolatedCopy() = 0; // Safe to pass be tween threads. 30 virtual std::unique_ptr<V8StackTrace> isolatedCopy() = 0; // Safe to pass be tween threads.
41 }; 31 };
42 32
43 } // namespace blink 33 } // namespace blink
44 34
45 #endif // V8StackTrace_h 35 #endif // V8StackTrace_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698