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

Side by Side Diff: mojo/public/interfaces/bindings/mojom_files.mojom

Issue 1741963002: Auto-formatted all .mojom files. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 9 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 [DartPackage="mojo", JavaPackage="org.chromium.mojo.bindings.types"] 5 [DartPackage="mojo",
6 JavaPackage="org.chromium.mojo.bindings.types"]
6 module mojo.bindings.types; 7 module mojo.bindings.types;
7 8
8 import "mojom_types.mojom"; 9 import "mojom_types.mojom";
9 10
10 /* 11 /*
11 * The structures in this file are intended to be used by the Mojom compiler 12 * The structures in this file are intended to be used by the Mojom compiler
12 * and code generators. The front end of the compiler takes as input a 13 * and code generators. The front end of the compiler takes as input a
13 * .mojom file (or a list of .mojom files) and produces a MojomFileGraph struct. 14 * .mojom file (or a list of .mojom files) and produces a MojomFileGraph struct.
14 * 15 *
15 * The backend of the compiler consumes a MojomFileGraph and invokes each of the 16 * The backend of the compiler consumes a MojomFileGraph and invokes each of the
16 * code generators passing them data derived from the MojomFileGraph. 17 * code generators passing them data derived from the MojomFileGraph.
17 * 18 *
18 * A MojomFile represents the data parsed from a single .mojom file. Mojom 19 * A MojomFile represents the data parsed from a single .mojom file. Mojom
19 * modules form a directed acyclic graph via the "imports" relation. 20 * modules form a directed acyclic graph via the "imports" relation.
20 * That is, if Module A imports Module B then there is a directed edge in the 21 * That is, if Module A imports Module B then there is a directed edge in the
21 * graph from A to B. A MojomFileGraph represents the whole Graph. 22 * graph from A to B. A MojomFileGraph represents the whole Graph.
22 23
23 * The Mojom structures represented here have been fully resolved, meaning that 24 * The Mojom structures represented here have been fully resolved, meaning that
24 * the type references have been associated with their corresponding type 25 * the type references have been associated with their corresponding type
25 * definitions. This resolved type data is contained in the resolved_types data 26 * definitions. This resolved type data is contained in the resolved_types data
26 * in MojomFileGraph. 27 * in MojomFileGraph.
27 */ 28 */
28 29
29 // A MojomFile represents the data defined by a single .mojom file, when 30 // A MojomFile represents the data defined by a single .mojom file, when
30 // all of the type references to types declared in imported .mojom files 31 // all of the type references to types declared in imported .mojom files
31 // have been resolved. 32 // have been resolved.
32 struct MojomFile { 33 struct MojomFile {
33 // |file_name| is (derived from) the file name of the corresponding 34 // |file_name| is (derived from) the file name of the corresponding
34 // .mojom file. It is the unique identifier for this module within the 35 // .mojom file. It is the unique identifier for this module within the
35 // MojomFileGraph 36 // MojomFileGraph
36 string file_name; 37 string file_name;
37 38
38 // |specified_file_name| is used to record information about the request that 39 // |specified_file_name| is used to record information about the request that
39 // triggered the construction of the |MojomFileGraph| of which this 40 // triggered the construction of the |MojomFileGraph| of which this
40 // |MojomFile| is a part. This field is populated by some producers (such 41 // |MojomFile| is a part. This field is populated by some producers (such
41 // as the Mojom compiler) but not necessarily all producers of this structure. 42 // as the Mojom compiler) but not necessarily all producers of this structure.
42 // If this field is null it means it is not supported by the producer. 43 // If this field is null it means it is not supported by the producer.
43 // 44 //
44 // If this field is non-null but empty it means that this |MojomFile| 45 // If this field is non-null but empty it means that this |MojomFile|
45 // was not explicitly requested but rather is included in the |MojomFileGraph| 46 // was not explicitly requested but rather is included in the |MojomFileGraph|
46 // because it is referenced in the |imports| field of another |MojomFile| 47 // because it is referenced in the |imports| field of another |MojomFile|
47 // in the graph. If this field is non-empty it means that the corresponding 48 // in the graph. If this field is non-empty it means that the corresponding
48 // .mojom file was explicitly requested, using |specified_file_name|. Note 49 // .mojom file was explicitly requested, using |specified_file_name|. Note
49 // that in this case it is still possible that this file is also referenced 50 // that in this case it is still possible that this file is also referenced
50 // in the |imports| field of another |MojomFile|. 51 // in the |imports| field of another |MojomFile|.
51 string? specified_file_name; 52 string? specified_file_name;
52 53
53 // The namespace is the identifier declared via the "module" declaration 54 // The namespace is the identifier declared via the "module" declaration
54 // in the .mojom file. 55 // in the .mojom file.
55 string? module_namespace; 56 string? module_namespace;
56 57
57 // Attributes declared in the Mojom file at the module level. 58 // Attributes declared in the Mojom file at the module level.
58 array<Attribute>? attributes; 59 array<Attribute>? attributes;
59 60
60 // The list of other MojomFiles imported by this one. The elements 61 // The list of other MojomFiles imported by this one. The elements
61 // of the array are the |file_name|s and the associated module may 62 // of the array are the |file_name|s and the associated module may
62 // be retrieved from the MojomFileGraph. 63 // be retrieved from the MojomFileGraph.
63 array<string>? imports; 64 array<string>? imports;
64 65
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 // type; 97 // type;
97 array<string>? interfaces; 98 array<string>? interfaces;
98 array<string>? structs; 99 array<string>? structs;
99 array<string>? unions; 100 array<string>? unions;
100 array<string>? top_level_enums; 101 array<string>? top_level_enums;
101 array<string>? embedded_enums; 102 array<string>? embedded_enums;
102 103
103 // All the constant_keys known to the owning MojomFileGraph. 104 // All the constant_keys known to the owning MojomFileGraph.
104 array<string>? top_level_constants; 105 array<string>? top_level_constants;
105 array<string>? embedded_constants; 106 array<string>? embedded_constants;
106 }; 107 };
OLDNEW
« no previous file with comments | « mojo/public/interfaces/bindings/interface_control_messages.mojom ('k') | mojo/public/interfaces/bindings/mojom_types.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698