OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFERENC E_H_ | 5 #ifndef CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFERENC E_H_ |
6 #define CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFERENC E_H_ | 6 #define CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFERENC E_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 23 matching lines...) Expand all Loading... | |
34 // ref-count. | 34 // ref-count. |
35 static std::unique_ptr<ServiceWorkerRegistrationHandleReference> Adopt( | 35 static std::unique_ptr<ServiceWorkerRegistrationHandleReference> Adopt( |
36 const ServiceWorkerRegistrationObjectInfo& info, | 36 const ServiceWorkerRegistrationObjectInfo& info, |
37 ThreadSafeSender* sender); | 37 ThreadSafeSender* sender); |
38 | 38 |
39 ~ServiceWorkerRegistrationHandleReference(); | 39 ~ServiceWorkerRegistrationHandleReference(); |
40 | 40 |
41 const ServiceWorkerRegistrationObjectInfo& info() const { return info_; } | 41 const ServiceWorkerRegistrationObjectInfo& info() const { return info_; } |
42 int handle_id() const { return info_.handle_id; } | 42 int handle_id() const { return info_.handle_id; } |
43 GURL scope() const { return info_.scope; } | 43 GURL scope() const { return info_.scope; } |
44 bool useCache() const { return info_.use_cache; } | |
nhiroki
2017/03/24 00:33:42
use_cache() (we use the snake_case under content/)
yuryu
2017/03/28 05:08:56
Done.
| |
44 int64_t registration_id() const { return info_.registration_id; } | 45 int64_t registration_id() const { return info_.registration_id; } |
45 | 46 |
46 private: | 47 private: |
47 ServiceWorkerRegistrationHandleReference( | 48 ServiceWorkerRegistrationHandleReference( |
48 const ServiceWorkerRegistrationObjectInfo& info, | 49 const ServiceWorkerRegistrationObjectInfo& info, |
49 ThreadSafeSender* sender, | 50 ThreadSafeSender* sender, |
50 bool increment_ref_in_ctor); | 51 bool increment_ref_in_ctor); |
51 | 52 |
52 ServiceWorkerRegistrationObjectInfo info_; | 53 ServiceWorkerRegistrationObjectInfo info_; |
53 scoped_refptr<ThreadSafeSender> sender_; | 54 scoped_refptr<ThreadSafeSender> sender_; |
54 | 55 |
55 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerRegistrationHandleReference); | 56 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerRegistrationHandleReference); |
56 }; | 57 }; |
57 | 58 |
58 } // namespace content | 59 } // namespace content |
59 | 60 |
60 #endif // CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFER ENCE_H_ | 61 #endif // CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_REGISTRATION_HANDLE_REFER ENCE_H_ |
OLD | NEW |