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

Side by Side Diff: mojo/public/c/include/mojo/bindings/array.h

Issue 2232833003: Change the canonical way to include the C bindings headers to <mojo/bindings/*.h>. (Closed) Base URL: https://github.com/domokit/mojo.git@work791_mojo_tests
Patch Set: rebased Created 4 years, 4 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
« no previous file with comments | « mojo/public/c/bindings/validation.h ('k') | mojo/public/c/include/mojo/bindings/buffer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef MOJO_PUBLIC_C_BINDINGS_ARRAY_H_ 5 #ifndef MOJO_PUBLIC_C_INCLUDE_MOJO_BINDINGS_ARRAY_H_
6 #define MOJO_PUBLIC_C_BINDINGS_ARRAY_H_ 6 #define MOJO_PUBLIC_C_INCLUDE_MOJO_BINDINGS_ARRAY_H_
7 7
8 #include <mojo/bindings/buffer.h>
9 #include <mojo/bindings/internal/type_descriptor.h>
8 #include <mojo/macros.h> 10 #include <mojo/macros.h>
9 #include <stdint.h> 11 #include <stdint.h>
10 12
11 #include "mojo/public/c/bindings/buffer.h"
12 #include "mojo/public/c/bindings/lib/type_descriptor.h"
13
14 MOJO_BEGIN_EXTERN_C 13 MOJO_BEGIN_EXTERN_C
15 14
16 // The fields below are just the header of a mojom array. The bytes that 15 // The fields below are just the header of a mojom array. The bytes that
17 // immediately follow this struct consist of |num_bytes - 16 // immediately follow this struct consist of |num_bytes -
18 // sizeof(MojomArrayHeader)| bytes describing |num_elements| elements of the 17 // sizeof(MojomArrayHeader)| bytes describing |num_elements| elements of the
19 // array. 18 // array.
20 struct MojomArrayHeader { 19 struct MojomArrayHeader {
21 // num_bytes includes the size of this struct along with the accompanying 20 // num_bytes includes the size of this struct along with the accompanying
22 // array bytes that follow these fields. 21 // array bytes that follow these fields.
23 uint32_t num_bytes; 22 uint32_t num_bytes;
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // |in_type_desc|: Describes the pointer and handle fields of the mojom array. 124 // |in_type_desc|: Describes the pointer and handle fields of the mojom array.
126 // |in_array|: The unencoded mojom array to be copied. 125 // |in_array|: The unencoded mojom array to be copied.
127 // |out_array|: Will be set to the new unencoded mojom array. 126 // |out_array|: Will be set to the new unencoded mojom array.
128 bool MojomArray_DeepCopy(struct MojomBuffer* buffer, 127 bool MojomArray_DeepCopy(struct MojomBuffer* buffer,
129 const struct MojomTypeDescriptorArray* in_type_desc, 128 const struct MojomTypeDescriptorArray* in_type_desc,
130 const struct MojomArrayHeader* in_array, 129 const struct MojomArrayHeader* in_array,
131 struct MojomArrayHeader** out_array); 130 struct MojomArrayHeader** out_array);
132 131
133 MOJO_END_EXTERN_C 132 MOJO_END_EXTERN_C
134 133
135 #endif // MOJO_PUBLIC_C_BINDINGS_ARRAY_H_ 134 #endif // MOJO_PUBLIC_C_INCLUDE_MOJO_BINDINGS_ARRAY_H_
OLDNEW
« no previous file with comments | « mojo/public/c/bindings/validation.h ('k') | mojo/public/c/include/mojo/bindings/buffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698