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

Side by Side Diff: mojo/public/interfaces/bindings/tests/sample_factory.mojom

Issue 814543006: Move //mojo/{public, edk} underneath //third_party (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 11 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
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 [JavaPackage="org.chromium.mojo.bindings.test.mojom.sample"]
6 module sample;
7
8 import "sample_import.mojom";
9
10 // This sample shows how handles to MessagePipes can be sent as both parameters
11 // to methods as well as fields on structs.
12
13 struct Request {
14 int32 x;
15 handle<message_pipe>? pipe;
16 array<handle<message_pipe>>? more_pipes;
17
18 // Interfaces can be used as members.
19 imported.ImportedInterface? obj;
20 };
21
22 struct Response {
23 int32 x;
24 handle<message_pipe>? pipe;
25 };
26
27 interface NamedObject {
28 SetName(string name);
29 GetName() => (string name);
30 };
31
32 [Client=FactoryClient]
33 interface Factory {
34 DoStuff(Request request, handle<message_pipe>? pipe);
35 DoStuff2(handle<data_pipe_consumer> pipe);
36 CreateNamedObject(NamedObject& obj);
37 RequestImportedInterface(
38 imported.ImportedInterface& obj) => (imported.ImportedInterface& obj);
39 TakeImportedInterface(
40 imported.ImportedInterface obj) => (imported.ImportedInterface obj);
41 };
42
43 interface FactoryClient {
44 DidStuff(Response response, string text);
45 DidStuff2(string text);
46 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698