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

Side by Side Diff: third_party/WebKit/Source/modules/budget/BudgetService.h

Issue 2229283003: Convert Budget to BudgetService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 Budget_h 5 #ifndef BudgetService_h
6 #define Budget_h 6 #define BudgetService_h
7 7
8 #include "bindings/core/v8/ScriptWrappable.h" 8 #include "bindings/core/v8/ScriptWrappable.h"
9 #include "modules/ModulesExport.h" 9 #include "modules/ModulesExport.h"
10 10
11 namespace blink { 11 namespace blink {
12 12
13 class ScriptPromise; 13 class ScriptPromise;
14 class ScriptState; 14 class ScriptState;
15 15
16 // This is the entry point into the browser for the Budget API, which is 16 // This is the entry point into the browser for the BudgetService API, which is
17 // designed to give origins the ability to perform background operations 17 // designed to give origins the ability to perform background operations
18 // on the user's behalf. 18 // on the user's behalf.
19 class Budget final : public GarbageCollected<Budget>, public ScriptWrappable { 19 class BudgetService final : public GarbageCollected<BudgetService>, public Scrip tWrappable {
harkness 2016/08/10 17:09:32 I don't really know whether to wrap this line, and
Peter Beverloo 2016/08/10 18:03:28 There are no line length limits in Blink, no need
20 DEFINE_WRAPPERTYPEINFO(); 20 DEFINE_WRAPPERTYPEINFO();
21 21
22 public: 22 public:
23 static Budget* create() 23 static BudgetService* create()
24 { 24 {
25 return new Budget(); 25 return new BudgetService();
26 } 26 }
27 27
28 ScriptPromise getCost(ScriptState*, const AtomicString& actionType); 28 ScriptPromise getCost(ScriptState*, const AtomicString& actionType);
29 ScriptPromise getBudget(ScriptState*); 29 ScriptPromise getBudget(ScriptState*);
30 30
31 DEFINE_INLINE_TRACE() {} 31 DEFINE_INLINE_TRACE() {}
32 32
33 private: 33 private:
34 Budget(); 34 BudgetService();
35 }; 35 };
36 36
37 } // namespace blink 37 } // namespace blink
38 38
39 #endif // Budget_h 39 #endif // BudgetService_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/budget/Budget.idl ('k') | third_party/WebKit/Source/modules/budget/BudgetService.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698