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

Unified Diff: services/shape_detection/shape_detection_service.h

Issue 2855203003: Shape Detection: move {BarcodeDetectionImpl,TextDetectionImpl}.java to //services/shape_detection (Closed)
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: services/shape_detection/shape_detection_service.h
diff --git a/services/shape_detection/shape_detection_service.h b/services/shape_detection/shape_detection_service.h
index 549349cccee7b53f8ceb6561fc40010d14376775..61ca7ef205725281a04199f82c2173042d41699c 100644
--- a/services/shape_detection/shape_detection_service.h
+++ b/services/shape_detection/shape_detection_service.h
@@ -10,6 +10,7 @@
#include "base/callback.h"
#include "base/macros.h"
#include "services/service_manager/public/cpp/binder_registry.h"
+#include "services/service_manager/public/cpp/interface_provider.h"
#include "services/service_manager/public/cpp/service.h"
#include "services/service_manager/public/cpp/service_context_ref.h"
@@ -27,8 +28,17 @@ class ShapeDetectionService : public service_manager::Service {
void OnBindInterface(const service_manager::BindSourceInfo& source_info,
const std::string& interface_name,
mojo::ScopedMessagePipeHandle interface_pipe) override;
-
private:
+#if defined(OS_ANDROID)
+ // Binds |java_interface_provider_| to an interface registry that exposes
+ // factories for the interfaces that are provided via Java on Android.
+ service_manager::InterfaceProvider* GetJavaInterfaces();
+
+ bool java_interface_provider_initialized_ = false;
+ // InterfaceProvider that is bound to the Java-side interface registry.
+ service_manager::InterfaceProvider java_interface_provider_;
Ken Rockot(use gerrit already) 2017/05/04 17:19:50 nit: Just use a unique_ptr<InterfaceProvider> inst
mcasas 2017/05/04 17:58:50 Yeah! I thought I recall somewhere (maybe "Do's a
+#endif
+
std::unique_ptr<service_manager::ServiceContextRefFactory> ref_factory_;
service_manager::BinderRegistry registry_;

Powered by Google App Engine
This is Rietveld 408576698