2018-09-13 23:04:55 +03:00
|
|
|
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2015-08-18 01:13:20 +03:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
|
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* The origin of this IDL file is
|
2016-05-10 07:35:35 +03:00
|
|
|
* https://w3c.github.io/performance-timeline/#the-performanceobserver-interface
|
2015-08-18 01:13:20 +03:00
|
|
|
*/
|
|
|
|
|
|
|
|
dictionary PerformanceObserverInit {
|
2019-04-12 19:29:48 +03:00
|
|
|
sequence<DOMString> entryTypes;
|
|
|
|
DOMString type;
|
|
|
|
boolean buffered;
|
2015-08-18 01:13:20 +03:00
|
|
|
};
|
|
|
|
|
2018-02-08 19:43:25 +03:00
|
|
|
callback PerformanceObserverCallback = void (PerformanceObserverEntryList entries,
|
|
|
|
PerformanceObserver observer);
|
2015-08-18 01:13:20 +03:00
|
|
|
|
2019-06-13 12:01:41 +03:00
|
|
|
[Pref="dom.enable_performance_observer",
|
2015-08-18 01:13:20 +03:00
|
|
|
Exposed=(Window,Worker)]
|
|
|
|
interface PerformanceObserver {
|
2019-09-12 14:01:17 +03:00
|
|
|
[Throws]
|
|
|
|
constructor(PerformanceObserverCallback callback);
|
|
|
|
|
2019-07-03 10:52:35 +03:00
|
|
|
[Throws] void observe(optional PerformanceObserverInit options = {});
|
2018-01-25 04:59:04 +03:00
|
|
|
void disconnect();
|
2018-02-08 19:43:25 +03:00
|
|
|
PerformanceEntryList takeRecords();
|
2019-04-12 19:29:48 +03:00
|
|
|
static readonly attribute object supportedEntryTypes;
|
2015-08-18 01:13:20 +03:00
|
|
|
};
|