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

Unified Diff: mojo/public/cpp/bindings/associated_group.h

Issue 1991463002: Mojo: Expose untyped associated endpoints through public API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « mojo/public/cpp/bindings/associated_binding.h ('k') | mojo/public/cpp/bindings/associated_interface_ptr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/cpp/bindings/associated_group.h
diff --git a/mojo/public/cpp/bindings/associated_group.h b/mojo/public/cpp/bindings/associated_group.h
index ea3b5a162659f5b2ad2ff60e595fe999975f525a..5f7a39632a487ec9515221b8a8e4f2dcbf1a7151 100644
--- a/mojo/public/cpp/bindings/associated_group.h
+++ b/mojo/public/cpp/bindings/associated_group.h
@@ -10,7 +10,7 @@
#include "base/memory/ref_counted.h"
#include "mojo/public/cpp/bindings/associated_interface_ptr_info.h"
#include "mojo/public/cpp/bindings/associated_interface_request.h"
-#include "mojo/public/cpp/bindings/lib/scoped_interface_endpoint_handle.h"
+#include "mojo/public/cpp/bindings/scoped_interface_endpoint_handle.h"
namespace mojo {
@@ -50,8 +50,8 @@ class AssociatedGroup {
AssociatedInterfaceConfig config,
AssociatedInterfacePtrInfo<T>* ptr_info,
AssociatedInterfaceRequest<T>* request) {
- internal::ScopedInterfaceEndpointHandle local;
- internal::ScopedInterfaceEndpointHandle remote;
+ ScopedInterfaceEndpointHandle local;
+ ScopedInterfaceEndpointHandle remote;
CreateEndpointHandlePair(&local, &remote);
if (!local.is_valid() || !remote.is_valid()) {
@@ -61,21 +61,19 @@ class AssociatedGroup {
}
if (config == WILL_PASS_PTR) {
- internal::AssociatedInterfacePtrInfoHelper::SetHandle(ptr_info,
- std::move(remote));
+ ptr_info->set_handle(std::move(remote));
+
// The implementation is local, therefore set the version according to
// the interface definition that this code is built against.
ptr_info->set_version(T::Version_);
- internal::AssociatedInterfaceRequestHelper::SetHandle(request,
- std::move(local));
+ request->Bind(std::move(local));
} else {
- internal::AssociatedInterfacePtrInfoHelper::SetHandle(ptr_info,
- std::move(local));
+ ptr_info->set_handle(std::move(local));
+
// The implementation is remote, we don't know about its actual version
// yet.
ptr_info->set_version(0u);
- internal::AssociatedInterfaceRequestHelper::SetHandle(request,
- std::move(remote));
+ request->Bind(std::move(remote));
}
}
@@ -83,8 +81,8 @@ class AssociatedGroup {
friend class internal::MultiplexRouter;
void CreateEndpointHandlePair(
- internal::ScopedInterfaceEndpointHandle* local_endpoint,
- internal::ScopedInterfaceEndpointHandle* remote_endpoint);
+ ScopedInterfaceEndpointHandle* local_endpoint,
+ ScopedInterfaceEndpointHandle* remote_endpoint);
scoped_refptr<internal::MultiplexRouter> router_;
};
« no previous file with comments | « mojo/public/cpp/bindings/associated_binding.h ('k') | mojo/public/cpp/bindings/associated_interface_ptr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698