2020-12-03 17:48:45 +00:00
|
|
|
// Copyright 2020 the V8 project authors. All rights reserved.
|
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
import {LogEntry} from './log.mjs';
|
|
|
|
|
|
|
|
export class ApiLogEntry extends LogEntry {
|
|
|
|
constructor(type, time, name) {
|
|
|
|
super(type, time);
|
|
|
|
this._name = name;
|
|
|
|
}
|
2020-12-07 08:44:54 +00:00
|
|
|
|
2020-12-03 17:48:45 +00:00
|
|
|
toString() {
|
2020-12-07 08:44:54 +00:00
|
|
|
return `Api(${this.type})`;
|
|
|
|
}
|
|
|
|
|
|
|
|
toStringLong() {
|
2020-12-03 17:48:45 +00:00
|
|
|
return `Api(${this.type}): ${this._name}`;
|
|
|
|
}
|
2020-12-07 08:44:54 +00:00
|
|
|
|
|
|
|
static get propertyNames() {
|
|
|
|
return ['type', 'name'];
|
|
|
|
}
|
2020-12-03 17:48:45 +00:00
|
|
|
}
|