| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ | 5 #ifndef COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ |
| 6 #define COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ | 6 #define COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 // Factory function for use as an embedded service. | 26 // Factory function for use as an embedded service. |
| 27 static std::unique_ptr<service_manager::Service> Create( | 27 static std::unique_ptr<service_manager::Service> Create( |
| 28 const std::string& creator); | 28 const std::string& creator); |
| 29 | 29 |
| 30 // service_manager::Service: | 30 // service_manager::Service: |
| 31 void OnStart() override; | 31 void OnStart() override; |
| 32 void OnBindInterface(const service_manager::BindSourceInfo& source_info, | 32 void OnBindInterface(const service_manager::BindSourceInfo& source_info, |
| 33 const std::string& interface_name, | 33 const std::string& interface_name, |
| 34 mojo::ScopedMessagePipeHandle interface_pipe) override; | 34 mojo::ScopedMessagePipeHandle interface_pipe) override; |
| 35 | 35 |
| 36 virtual void PrepareToStart(); |
| 37 |
| 36 private: | 38 private: |
| 37 // The creator of this service. | 39 // The creator of this service. |
| 38 // Currently contains the service creator's user agent string if given, | 40 // Currently contains the service creator's user agent string if given, |
| 39 // otherwise just use string "Chromium". | 41 // otherwise just use string "Chromium". |
| 40 const std::string creator_; | 42 const std::string creator_; |
| 41 | 43 |
| 42 std::unique_ptr<discardable_memory::ClientDiscardableSharedMemoryManager> | 44 std::unique_ptr<discardable_memory::ClientDiscardableSharedMemoryManager> |
| 43 discardable_shared_memory_manager_; | 45 discardable_shared_memory_manager_; |
| 44 std::unique_ptr<service_manager::ServiceContextRefFactory> ref_factory_; | 46 std::unique_ptr<service_manager::ServiceContextRefFactory> ref_factory_; |
| 45 service_manager::BinderRegistry registry_; | 47 service_manager::BinderRegistry registry_; |
| 46 base::WeakPtrFactory<PdfCompositorService> weak_factory_; | 48 base::WeakPtrFactory<PdfCompositorService> weak_factory_; |
| 47 | 49 |
| 48 DISALLOW_COPY_AND_ASSIGN(PdfCompositorService); | 50 DISALLOW_COPY_AND_ASSIGN(PdfCompositorService); |
| 49 }; | 51 }; |
| 50 | 52 |
| 51 } // namespace printing | 53 } // namespace printing |
| 52 | 54 |
| 53 #endif // COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ | 55 #endif // COMPONENTS_PRINTING_SERVICE_PDF_COMPOSITOR_SERVICE_H_ |
| OLD | NEW |