| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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 import "sample_import.mojom" | 5 import "sample_import.mojom" |
| 6 import "sample_import2.mojom" | 6 import "sample_import2.mojom" |
| 7 | 7 |
| 8 module sample { | 8 module sample { |
| 9 | 9 |
| 10 enum BarType { | 10 enum BarType { |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 int32 age @2; | 41 int32 age @2; |
| 42 string[] names = ["Jim"] @1; | 42 string[] names = ["Jim"] @1; |
| 43 int32 height = 6*12 @3; | 43 int32 height = 6*12 @3; |
| 44 }; | 44 }; |
| 45 | 45 |
| 46 struct DefaultsTest { | 46 struct DefaultsTest { |
| 47 sample.DefaultsTestInner[] people = [{32, ["Bob", "Bobby"]}] @1; | 47 sample.DefaultsTestInner[] people = [{32, ["Bob", "Bobby"]}] @1; |
| 48 uint8[] data = [1, 2, 3] @2; | 48 uint8[] data = [1, 2, 3] @2; |
| 49 imported.Point point = {7, 15} @3; | 49 imported.Point point = {7, 15} @3; |
| 50 int32[] shape_masks = [1 << imported.SHAPE_RECTANGLE] @4; | 50 int32[] shape_masks = [1 << imported.SHAPE_RECTANGLE] @4; |
| 51 imported.Thing thing = {imported.SHAPE_RECTANGLE, imported.COLOR_RED}; | 51 imported.Thing thing = {imported.SHAPE_CIRCLE, imported.COLOR_BLACK}; |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 interface Port { | 54 interface Port { |
| 55 void PostMessage(string message_text @0) @0; | 55 void PostMessage(string message_text @0) @0; |
| 56 }; | 56 }; |
| 57 | 57 |
| 58 [Peer=ServiceClient] | 58 [Peer=ServiceClient] |
| 59 interface Service { | 59 interface Service { |
| 60 enum BazOptions { | 60 enum BazOptions { |
| 61 BAZ_REGULAR = 0, | 61 BAZ_REGULAR = 0, |
| 62 BAZ_EXTRA | 62 BAZ_EXTRA |
| 63 }; | 63 }; |
| 64 void Frobinate(Foo foo @0, int32 baz @1, Port port @2) @0; | 64 void Frobinate(Foo foo @0, int32 baz @1, Port port @2) @0; |
| 65 }; | 65 }; |
| 66 | 66 |
| 67 [Peer=Service] | 67 [Peer=Service] |
| 68 interface ServiceClient { | 68 interface ServiceClient { |
| 69 void DidFrobinate(int32 result @0) @0; | 69 void DidFrobinate(int32 result @0) @0; |
| 70 }; | 70 }; |
| 71 | 71 |
| 72 } | 72 } |
| OLD | NEW |