v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
trace-event-listener.h
Go to the documentation of this file.
1
// Copyright 2019 the V8 project authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef V8_LIBPLATFORM_TRACING_TRACE_EVENT_LISTENER_H_
6
#define V8_LIBPLATFORM_TRACING_TRACE_EVENT_LISTENER_H_
7
8
#include <vector>
9
10
#include "
libplatform/libplatform-export.h
"
11
12
namespace
v8
{
13
namespace
platform {
14
namespace
tracing {
15
16
// A TraceEventListener is a simple interface that allows subclasses to listen
17
// to trace events. This interface is to hide the more complex interactions that
18
// the PerfettoConsumer class has to perform. Clients override ParseFromArray()
19
// to process traces, e.g. to write them to a file as JSON or for testing
20
// purposes.
21
class
V8_PLATFORM_EXPORT
TraceEventListener
{
22
public
:
23
virtual
~TraceEventListener
() =
default
;
24
virtual
void
ParseFromArray
(
const
std::vector<char>& array) = 0;
25
};
26
27
}
// namespace tracing
28
}
// namespace platform
29
}
// namespace v8
30
31
#endif
// V8_LIBPLATFORM_TRACING_TRACE_EVENT_LISTENER_H_
v8::platform::tracing::TraceEventListener
Definition
trace-event-listener.h:21
v8::platform::tracing::TraceEventListener::~TraceEventListener
virtual ~TraceEventListener()=default
v8::platform::tracing::TraceEventListener::ParseFromArray
virtual void ParseFromArray(const std::vector< char > &array)=0
libplatform-export.h
V8_PLATFORM_EXPORT
#define V8_PLATFORM_EXPORT
Definition
libplatform-export.h:24
v8
Definition
api-arguments-inl.h:19
src
libplatform
tracing
trace-event-listener.h
Generated on Sun Apr 6 2025 21:08:54 for v8 by
1.12.0