| Index: Source/core/timing/Performance.idl
|
| diff --git a/Source/core/timing/Performance.idl b/Source/core/timing/Performance.idl
|
| index 6a8fab6b0030ec60e72d6f7d0230919d69f66bae..07cf38a88e5f0c48da8cc95b28a9e06a0699aa90 100644
|
| --- a/Source/core/timing/Performance.idl
|
| +++ b/Source/core/timing/Performance.idl
|
| @@ -29,21 +29,37 @@
|
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| */
|
|
|
| +// http://w3c.github.io/performance-timeline/#entryType/index.html#idl-def-PerformanceEntryType
|
| +enum PerformanceEntryType {
|
| + "composite",
|
| + "mark",
|
| + "measure",
|
| + "navigation",
|
| + "render",
|
| + "resource",
|
| + "server"
|
| +};
|
| +
|
| +// http://w3c.github.io/performance-timeline/#idl-def-PerformanceObserverCallback
|
| +callback PerformanceObserverCallback = void (PerformanceObserverEntryList entries, PerformanceObserver observer);
|
| +
|
| // https://w3c.github.io/hr-time/#the-performance-interface
|
|
|
| // TODO(philipj): This interface should be [Exposed=(Window,Worker)]. Doing that
|
| // would allow the WorkerPerformance interface to be merged into this.
|
| // TODO(philipj): None of the optional DOMString arguments in this interface
|
| // should have a default value.
|
| -interface Performance : EventTarget {
|
| +[
|
| + GarbageCollected
|
| +] interface Performance : EventTarget {
|
| DOMHighResTimeStamp now();
|
|
|
| // Performance Timeline
|
| // https://w3c.github.io/performance-timeline/#the-performance-interface
|
| // TODO(philipj): getEntries() should take an optional FilterOptions argument.
|
| [MeasureAs=UnprefixedPerformanceTimeline] PerformanceEntryList getEntries();
|
| - [MeasureAs=UnprefixedPerformanceTimeline] PerformanceEntryList getEntriesByType(DOMString entryType);
|
| - [MeasureAs=UnprefixedPerformanceTimeline] PerformanceEntryList getEntriesByName(DOMString name, optional DOMString entryType = null);
|
| + [MeasureAs=UnprefixedPerformanceTimeline] PerformanceEntryList getEntriesByType(PerformanceEntryType entryType);
|
| + [MeasureAs=UnprefixedPerformanceTimeline] PerformanceEntryList getEntriesByName(DOMString name, optional PerformanceEntryType entryType = null);
|
|
|
| // Resource Timing
|
| // https://w3c.github.io/resource-timing/#extensions-performance-interface
|
| @@ -75,6 +91,10 @@ interface Performance : EventTarget {
|
| [RuntimeEnabled=FrameTimingSupport, MeasureAs=PerformanceFrameTiming] void setFrameTimingBufferSize(unsigned long maxSize);
|
| [RuntimeEnabled=FrameTimingSupport] attribute EventHandler onframetimingbufferfull;
|
|
|
| + // Performance Observer
|
| + // http://w3c.github.io/performance-timeline/#extensions-to-the-performance-interface-1
|
| + [Custom, RuntimeEnabled=PerformanceObserverSupport] PerformanceObserver createPerformanceObserver(PerformanceObserverCallback callback);
|
| +
|
| // TODO(philipj): There is no spec for the Memory Info API, see blink-dev:
|
| // https://groups.google.com/a/chromium.org/d/msg/blink-dev/g5YRCGpC9vs/b4OJz71NmPwJ
|
| [Measure] readonly attribute MemoryInfo memory;
|
|
|