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

Side by Side Diff: third_party/WebKit/Source/core/timing/PerformanceObserver.h

Issue 2799093004: Enable ServerTiming support
Patch Set: server-timing Created 3 years, 8 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 PerformanceObserver_h 5 #ifndef PerformanceObserver_h
6 #define PerformanceObserver_h 6 #define PerformanceObserver_h
7 7
8 #include "bindings/core/v8/TraceWrapperMember.h" 8 #include "bindings/core/v8/TraceWrapperMember.h"
9 #include "core/CoreExport.h" 9 #include "core/CoreExport.h"
10 #include "core/timing/PerformanceEntry.h" 10 #include "core/timing/PerformanceEntry.h"
(...skipping 21 matching lines...) Expand all
32 32
33 public: 33 public:
34 static PerformanceObserver* Create(ExecutionContext*, 34 static PerformanceObserver* Create(ExecutionContext*,
35 PerformanceBase*, 35 PerformanceBase*,
36 PerformanceObserverCallback*); 36 PerformanceObserverCallback*);
37 static void ResumeSuspendedObservers(); 37 static void ResumeSuspendedObservers();
38 38
39 void observe(const PerformanceObserverInit&, ExceptionState&); 39 void observe(const PerformanceObserverInit&, ExceptionState&);
40 void disconnect(); 40 void disconnect();
41 void EnqueuePerformanceEntry(PerformanceEntry&); 41 void EnqueuePerformanceEntry(PerformanceEntry&);
42 void MaybeEnqueuePerformanceEntry(PerformanceEntry&);
42 PerformanceEntryTypeMask FilterOptions() const { return filter_options_; } 43 PerformanceEntryTypeMask FilterOptions() const { return filter_options_; }
43 44
44 DECLARE_TRACE(); 45 DECLARE_TRACE();
45 DECLARE_TRACE_WRAPPERS(); 46 DECLARE_TRACE_WRAPPERS();
46 47
47 private: 48 private:
48 PerformanceObserver(ExecutionContext*, 49 PerformanceObserver(ExecutionContext*,
49 PerformanceBase*, 50 PerformanceBase*,
50 PerformanceObserverCallback*); 51 PerformanceObserverCallback*);
51 void Deliver(); 52 void Deliver();
52 bool ShouldBeSuspended() const; 53 bool ShouldBeSuspended() const;
53 54
54 Member<ExecutionContext> execution_context_; 55 Member<ExecutionContext> execution_context_;
55 TraceWrapperMember<PerformanceObserverCallback> callback_; 56 TraceWrapperMember<PerformanceObserverCallback> callback_;
56 WeakMember<PerformanceBase> performance_; 57 WeakMember<PerformanceBase> performance_;
57 PerformanceEntryVector performance_entries_; 58 PerformanceEntryVector performance_entries_;
58 PerformanceEntryTypeMask filter_options_; 59 PerformanceEntryTypeMask filter_options_;
59 bool is_registered_; 60 bool is_registered_;
60 }; 61 };
61 62
62 } // namespace blink 63 } // namespace blink
63 64
64 #endif // PerformanceObserver_h 65 #endif // PerformanceObserver_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698