@bufbuild/protobuf 2.0.0-alpha.3 → 2.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (130) hide show
  1. package/dist/cjs/clone.d.ts +1 -1
  2. package/dist/cjs/clone.js +9 -17
  3. package/dist/cjs/codegenv1/embed.js +25 -25
  4. package/dist/cjs/codegenv1/enum.d.ts +2 -1
  5. package/dist/cjs/codegenv1/file.js +1 -1
  6. package/dist/cjs/codegenv1/message.d.ts +2 -1
  7. package/dist/cjs/codegenv1/scalar.d.ts +4 -0
  8. package/dist/cjs/codegenv1/scalar.js +30 -1
  9. package/dist/cjs/codegenv1/symbols.d.ts +10 -0
  10. package/dist/cjs/codegenv1/symbols.js +2 -0
  11. package/dist/cjs/codegenv1/types.d.ts +7 -5
  12. package/dist/cjs/codegenv1/types.js +2 -1
  13. package/dist/cjs/create.d.ts +1 -1
  14. package/dist/cjs/create.js +47 -20
  15. package/dist/cjs/equals.d.ts +1 -1
  16. package/dist/cjs/equals.js +8 -15
  17. package/dist/cjs/from-binary.d.ts +2 -2
  18. package/dist/cjs/from-binary.js +17 -14
  19. package/dist/cjs/from-json.d.ts +14 -6
  20. package/dist/cjs/from-json.js +51 -55
  21. package/dist/cjs/is-message.d.ts +1 -1
  22. package/dist/cjs/is-message.js +3 -3
  23. package/dist/cjs/reflect/guard.js +4 -4
  24. package/dist/cjs/reflect/reflect-types.d.ts +13 -80
  25. package/dist/cjs/reflect/reflect.d.ts +29 -18
  26. package/dist/cjs/reflect/reflect.js +183 -78
  27. package/dist/cjs/reflect/scalar.d.ts +1 -1
  28. package/dist/cjs/reflect/unsafe.d.ts +0 -16
  29. package/dist/cjs/reflect/unsafe.js +1 -19
  30. package/dist/cjs/registry.d.ts +18 -2
  31. package/dist/cjs/registry.js +62 -60
  32. package/dist/cjs/to-binary.d.ts +1 -1
  33. package/dist/cjs/to-binary.js +2 -2
  34. package/dist/cjs/to-json.d.ts +14 -4
  35. package/dist/cjs/to-json.js +26 -13
  36. package/dist/cjs/types.d.ts +9 -0
  37. package/dist/cjs/wire/binary-encoding.js +30 -9
  38. package/dist/cjs/wkt/any.d.ts +7 -7
  39. package/dist/cjs/wkt/any.js +5 -5
  40. package/dist/cjs/wkt/gen/google/protobuf/any_pb.d.ts +9 -3
  41. package/dist/cjs/wkt/gen/google/protobuf/any_pb.js +4 -4
  42. package/dist/cjs/wkt/gen/google/protobuf/api_pb.d.ts +88 -9
  43. package/dist/cjs/wkt/gen/google/protobuf/api_pb.js +8 -8
  44. package/dist/cjs/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +107 -11
  45. package/dist/cjs/wkt/gen/google/protobuf/compiler/plugin_pb.js +11 -11
  46. package/dist/cjs/wkt/gen/google/protobuf/descriptor_pb.d.ts +1005 -92
  47. package/dist/cjs/wkt/gen/google/protobuf/descriptor_pb.js +86 -86
  48. package/dist/cjs/wkt/gen/google/protobuf/duration_pb.d.ts +7 -3
  49. package/dist/cjs/wkt/gen/google/protobuf/duration_pb.js +4 -4
  50. package/dist/cjs/wkt/gen/google/protobuf/empty_pb.d.ts +7 -3
  51. package/dist/cjs/wkt/gen/google/protobuf/empty_pb.js +4 -4
  52. package/dist/cjs/wkt/gen/google/protobuf/field_mask_pb.d.ts +7 -3
  53. package/dist/cjs/wkt/gen/google/protobuf/field_mask_pb.js +4 -4
  54. package/dist/cjs/wkt/gen/google/protobuf/source_context_pb.d.ts +12 -3
  55. package/dist/cjs/wkt/gen/google/protobuf/source_context_pb.js +4 -4
  56. package/dist/cjs/wkt/gen/google/protobuf/struct_pb.d.ts +25 -8
  57. package/dist/cjs/wkt/gen/google/protobuf/struct_pb.js +9 -9
  58. package/dist/cjs/wkt/gen/google/protobuf/timestamp_pb.d.ts +7 -3
  59. package/dist/cjs/wkt/gen/google/protobuf/timestamp_pb.js +4 -4
  60. package/dist/cjs/wkt/gen/google/protobuf/type_pb.d.ts +165 -16
  61. package/dist/cjs/wkt/gen/google/protobuf/type_pb.js +15 -15
  62. package/dist/cjs/wkt/gen/google/protobuf/wrappers_pb.d.ts +55 -19
  63. package/dist/cjs/wkt/gen/google/protobuf/wrappers_pb.js +20 -20
  64. package/dist/cjs/wkt/timestamp.js +1 -2
  65. package/dist/esm/clone.d.ts +1 -1
  66. package/dist/esm/clone.js +9 -17
  67. package/dist/esm/codegenv1/embed.js +26 -26
  68. package/dist/esm/codegenv1/enum.d.ts +2 -1
  69. package/dist/esm/codegenv1/file.js +2 -2
  70. package/dist/esm/codegenv1/message.d.ts +2 -1
  71. package/dist/esm/codegenv1/scalar.d.ts +4 -0
  72. package/dist/esm/codegenv1/scalar.js +28 -0
  73. package/dist/esm/codegenv1/symbols.d.ts +10 -0
  74. package/dist/esm/codegenv1/symbols.js +2 -0
  75. package/dist/esm/codegenv1/types.d.ts +7 -5
  76. package/dist/esm/codegenv1/types.js +2 -1
  77. package/dist/esm/create.d.ts +1 -1
  78. package/dist/esm/create.js +47 -20
  79. package/dist/esm/equals.d.ts +1 -1
  80. package/dist/esm/equals.js +8 -15
  81. package/dist/esm/from-binary.d.ts +2 -2
  82. package/dist/esm/from-binary.js +17 -14
  83. package/dist/esm/from-json.d.ts +14 -6
  84. package/dist/esm/from-json.js +49 -55
  85. package/dist/esm/is-message.d.ts +1 -1
  86. package/dist/esm/is-message.js +3 -3
  87. package/dist/esm/reflect/guard.js +4 -4
  88. package/dist/esm/reflect/reflect-types.d.ts +13 -80
  89. package/dist/esm/reflect/reflect-types.js +0 -1
  90. package/dist/esm/reflect/reflect.d.ts +29 -18
  91. package/dist/esm/reflect/reflect.js +185 -80
  92. package/dist/esm/reflect/scalar.d.ts +1 -1
  93. package/dist/esm/reflect/unsafe.d.ts +0 -16
  94. package/dist/esm/reflect/unsafe.js +0 -16
  95. package/dist/esm/registry.d.ts +18 -2
  96. package/dist/esm/registry.js +60 -59
  97. package/dist/esm/to-binary.d.ts +1 -1
  98. package/dist/esm/to-binary.js +2 -2
  99. package/dist/esm/to-json.d.ts +14 -4
  100. package/dist/esm/to-json.js +24 -12
  101. package/dist/esm/types.d.ts +9 -0
  102. package/dist/esm/wire/binary-encoding.js +30 -9
  103. package/dist/esm/wkt/any.d.ts +7 -7
  104. package/dist/esm/wkt/any.js +6 -6
  105. package/dist/esm/wkt/gen/google/protobuf/any_pb.d.ts +9 -3
  106. package/dist/esm/wkt/gen/google/protobuf/any_pb.js +3 -3
  107. package/dist/esm/wkt/gen/google/protobuf/api_pb.d.ts +88 -9
  108. package/dist/esm/wkt/gen/google/protobuf/api_pb.js +9 -9
  109. package/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +107 -11
  110. package/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.js +11 -11
  111. package/dist/esm/wkt/gen/google/protobuf/descriptor_pb.d.ts +1005 -92
  112. package/dist/esm/wkt/gen/google/protobuf/descriptor_pb.js +84 -84
  113. package/dist/esm/wkt/gen/google/protobuf/duration_pb.d.ts +7 -3
  114. package/dist/esm/wkt/gen/google/protobuf/duration_pb.js +3 -3
  115. package/dist/esm/wkt/gen/google/protobuf/empty_pb.d.ts +7 -3
  116. package/dist/esm/wkt/gen/google/protobuf/empty_pb.js +3 -3
  117. package/dist/esm/wkt/gen/google/protobuf/field_mask_pb.d.ts +7 -3
  118. package/dist/esm/wkt/gen/google/protobuf/field_mask_pb.js +3 -3
  119. package/dist/esm/wkt/gen/google/protobuf/source_context_pb.d.ts +12 -3
  120. package/dist/esm/wkt/gen/google/protobuf/source_context_pb.js +3 -3
  121. package/dist/esm/wkt/gen/google/protobuf/struct_pb.d.ts +25 -8
  122. package/dist/esm/wkt/gen/google/protobuf/struct_pb.js +8 -8
  123. package/dist/esm/wkt/gen/google/protobuf/timestamp_pb.d.ts +7 -3
  124. package/dist/esm/wkt/gen/google/protobuf/timestamp_pb.js +3 -3
  125. package/dist/esm/wkt/gen/google/protobuf/type_pb.d.ts +165 -16
  126. package/dist/esm/wkt/gen/google/protobuf/type_pb.js +16 -16
  127. package/dist/esm/wkt/gen/google/protobuf/wrappers_pb.d.ts +55 -19
  128. package/dist/esm/wkt/gen/google/protobuf/wrappers_pb.js +19 -19
  129. package/dist/esm/wkt/timestamp.js +2 -3
  130. package/package.json +2 -2
@@ -1,11 +1,11 @@
1
1
  import type { GenDescFile, GenDescMessage } from "../../../../codegenv1/types.js";
2
- import type { SourceContext } from "./source_context_pb.js";
3
- import type { Option, Syntax } from "./type_pb.js";
2
+ import type { SourceContext, SourceContextJson } from "./source_context_pb.js";
3
+ import type { Option, OptionJson, Syntax, SyntaxJson } from "./type_pb.js";
4
4
  import type { Message } from "../../../../types.js";
5
5
  /**
6
6
  * Describes the file google/protobuf/api.proto.
7
7
  */
8
- export declare const fileDesc_google_protobuf_api: GenDescFile;
8
+ export declare const file_google_protobuf_api: GenDescFile;
9
9
  /**
10
10
  * Api is a light-weight descriptor for an API Interface.
11
11
  *
@@ -84,11 +84,44 @@ export type Api = Message<"google.protobuf.Api"> & {
84
84
  */
85
85
  syntax: Syntax;
86
86
  };
87
+ /**
88
+ * JSON type for the message google.protobuf.Api.
89
+ */
90
+ export type ApiJson = {
91
+ /**
92
+ * @generated from field: string name = 1;
93
+ */
94
+ name?: string;
95
+ /**
96
+ * @generated from field: repeated google.protobuf.Method methods = 2;
97
+ */
98
+ methods?: MethodJson[];
99
+ /**
100
+ * @generated from field: repeated google.protobuf.Option options = 3;
101
+ */
102
+ options?: OptionJson[];
103
+ /**
104
+ * @generated from field: string version = 4;
105
+ */
106
+ version?: string;
107
+ /**
108
+ * @generated from field: google.protobuf.SourceContext source_context = 5;
109
+ */
110
+ sourceContext?: SourceContextJson;
111
+ /**
112
+ * @generated from field: repeated google.protobuf.Mixin mixins = 6;
113
+ */
114
+ mixins?: MixinJson[];
115
+ /**
116
+ * @generated from field: google.protobuf.Syntax syntax = 7;
117
+ */
118
+ syntax?: SyntaxJson;
119
+ };
87
120
  /**
88
121
  * Describes the message google.protobuf.Api.
89
- * Use `create(ApiDesc)` to create a new message.
122
+ * Use `create(ApiSchema)` to create a new message.
90
123
  */
91
- export declare const ApiDesc: GenDescMessage<Api>;
124
+ export declare const ApiSchema: GenDescMessage<Api, ApiJson>;
92
125
  /**
93
126
  * Method represents a method of an API interface.
94
127
  *
@@ -138,11 +171,44 @@ export type Method = Message<"google.protobuf.Method"> & {
138
171
  */
139
172
  syntax: Syntax;
140
173
  };
174
+ /**
175
+ * JSON type for the message google.protobuf.Method.
176
+ */
177
+ export type MethodJson = {
178
+ /**
179
+ * @generated from field: string name = 1;
180
+ */
181
+ name?: string;
182
+ /**
183
+ * @generated from field: string request_type_url = 2;
184
+ */
185
+ requestTypeUrl?: string;
186
+ /**
187
+ * @generated from field: bool request_streaming = 3;
188
+ */
189
+ requestStreaming?: boolean;
190
+ /**
191
+ * @generated from field: string response_type_url = 4;
192
+ */
193
+ responseTypeUrl?: string;
194
+ /**
195
+ * @generated from field: bool response_streaming = 5;
196
+ */
197
+ responseStreaming?: boolean;
198
+ /**
199
+ * @generated from field: repeated google.protobuf.Option options = 6;
200
+ */
201
+ options?: OptionJson[];
202
+ /**
203
+ * @generated from field: google.protobuf.Syntax syntax = 7;
204
+ */
205
+ syntax?: SyntaxJson;
206
+ };
141
207
  /**
142
208
  * Describes the message google.protobuf.Method.
143
- * Use `create(MethodDesc)` to create a new message.
209
+ * Use `create(MethodSchema)` to create a new message.
144
210
  */
145
- export declare const MethodDesc: GenDescMessage<Method>;
211
+ export declare const MethodSchema: GenDescMessage<Method, MethodJson>;
146
212
  /**
147
213
  * Declares an API Interface to be included in this interface. The including
148
214
  * interface must redeclare all the methods from the included interface, but
@@ -240,8 +306,21 @@ export type Mixin = Message<"google.protobuf.Mixin"> & {
240
306
  */
241
307
  root: string;
242
308
  };
309
+ /**
310
+ * JSON type for the message google.protobuf.Mixin.
311
+ */
312
+ export type MixinJson = {
313
+ /**
314
+ * @generated from field: string name = 1;
315
+ */
316
+ name?: string;
317
+ /**
318
+ * @generated from field: string root = 2;
319
+ */
320
+ root?: string;
321
+ };
243
322
  /**
244
323
  * Describes the message google.protobuf.Mixin.
245
- * Use `create(MixinDesc)` to create a new message.
324
+ * Use `create(MixinSchema)` to create a new message.
246
325
  */
247
- export declare const MixinDesc: GenDescMessage<Mixin>;
326
+ export declare const MixinSchema: GenDescMessage<Mixin, MixinJson>;
@@ -12,25 +12,25 @@
12
12
  // See the License for the specific language governing permissions and
13
13
  // limitations under the License.
14
14
  import { fileDesc } from "../../../../codegenv1/file.js";
15
- import { fileDesc_google_protobuf_source_context } from "./source_context_pb.js";
16
- import { fileDesc_google_protobuf_type } from "./type_pb.js";
15
+ import { file_google_protobuf_source_context } from "./source_context_pb.js";
16
+ import { file_google_protobuf_type } from "./type_pb.js";
17
17
  import { messageDesc } from "../../../../codegenv1/message.js";
18
18
  /**
19
19
  * Describes the file google/protobuf/api.proto.
20
20
  */
21
- export const fileDesc_google_protobuf_api = /*@__PURE__*/ fileDesc("Chlnb29nbGUvcHJvdG9idWYvYXBpLnByb3RvEg9nb29nbGUucHJvdG9idWYigQIKA0FwaRIMCgRuYW1lGAEgASgJEigKB21ldGhvZHMYAiADKAsyFy5nb29nbGUucHJvdG9idWYuTWV0aG9kEigKB29wdGlvbnMYAyADKAsyFy5nb29nbGUucHJvdG9idWYuT3B0aW9uEg8KB3ZlcnNpb24YBCABKAkSNgoOc291cmNlX2NvbnRleHQYBSABKAsyHi5nb29nbGUucHJvdG9idWYuU291cmNlQ29udGV4dBImCgZtaXhpbnMYBiADKAsyFi5nb29nbGUucHJvdG9idWYuTWl4aW4SJwoGc3ludGF4GAcgASgOMhcuZ29vZ2xlLnByb3RvYnVmLlN5bnRheCLVAQoGTWV0aG9kEgwKBG5hbWUYASABKAkSGAoQcmVxdWVzdF90eXBlX3VybBgCIAEoCRIZChFyZXF1ZXN0X3N0cmVhbWluZxgDIAEoCBIZChFyZXNwb25zZV90eXBlX3VybBgEIAEoCRIaChJyZXNwb25zZV9zdHJlYW1pbmcYBSABKAgSKAoHb3B0aW9ucxgGIAMoCzIXLmdvb2dsZS5wcm90b2J1Zi5PcHRpb24SJwoGc3ludGF4GAcgASgOMhcuZ29vZ2xlLnByb3RvYnVmLlN5bnRheCIjCgVNaXhpbhIMCgRuYW1lGAEgASgJEgwKBHJvb3QYAiABKAlCdgoTY29tLmdvb2dsZS5wcm90b2J1ZkIIQXBpUHJvdG9QAVosZ29vZ2xlLmdvbGFuZy5vcmcvcHJvdG9idWYvdHlwZXMva25vd24vYXBpcGKiAgNHUEKqAh5Hb29nbGUuUHJvdG9idWYuV2VsbEtub3duVHlwZXNiBnByb3RvMw", [fileDesc_google_protobuf_source_context, fileDesc_google_protobuf_type]);
21
+ export const file_google_protobuf_api = /*@__PURE__*/ fileDesc("Chlnb29nbGUvcHJvdG9idWYvYXBpLnByb3RvEg9nb29nbGUucHJvdG9idWYigQIKA0FwaRIMCgRuYW1lGAEgASgJEigKB21ldGhvZHMYAiADKAsyFy5nb29nbGUucHJvdG9idWYuTWV0aG9kEigKB29wdGlvbnMYAyADKAsyFy5nb29nbGUucHJvdG9idWYuT3B0aW9uEg8KB3ZlcnNpb24YBCABKAkSNgoOc291cmNlX2NvbnRleHQYBSABKAsyHi5nb29nbGUucHJvdG9idWYuU291cmNlQ29udGV4dBImCgZtaXhpbnMYBiADKAsyFi5nb29nbGUucHJvdG9idWYuTWl4aW4SJwoGc3ludGF4GAcgASgOMhcuZ29vZ2xlLnByb3RvYnVmLlN5bnRheCLVAQoGTWV0aG9kEgwKBG5hbWUYASABKAkSGAoQcmVxdWVzdF90eXBlX3VybBgCIAEoCRIZChFyZXF1ZXN0X3N0cmVhbWluZxgDIAEoCBIZChFyZXNwb25zZV90eXBlX3VybBgEIAEoCRIaChJyZXNwb25zZV9zdHJlYW1pbmcYBSABKAgSKAoHb3B0aW9ucxgGIAMoCzIXLmdvb2dsZS5wcm90b2J1Zi5PcHRpb24SJwoGc3ludGF4GAcgASgOMhcuZ29vZ2xlLnByb3RvYnVmLlN5bnRheCIjCgVNaXhpbhIMCgRuYW1lGAEgASgJEgwKBHJvb3QYAiABKAlCdgoTY29tLmdvb2dsZS5wcm90b2J1ZkIIQXBpUHJvdG9QAVosZ29vZ2xlLmdvbGFuZy5vcmcvcHJvdG9idWYvdHlwZXMva25vd24vYXBpcGKiAgNHUEKqAh5Hb29nbGUuUHJvdG9idWYuV2VsbEtub3duVHlwZXNiBnByb3RvMw", [file_google_protobuf_source_context, file_google_protobuf_type]);
22
22
  /**
23
23
  * Describes the message google.protobuf.Api.
24
- * Use `create(ApiDesc)` to create a new message.
24
+ * Use `create(ApiSchema)` to create a new message.
25
25
  */
26
- export const ApiDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_api, 0);
26
+ export const ApiSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_api, 0);
27
27
  /**
28
28
  * Describes the message google.protobuf.Method.
29
- * Use `create(MethodDesc)` to create a new message.
29
+ * Use `create(MethodSchema)` to create a new message.
30
30
  */
31
- export const MethodDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_api, 1);
31
+ export const MethodSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_api, 1);
32
32
  /**
33
33
  * Describes the message google.protobuf.Mixin.
34
- * Use `create(MixinDesc)` to create a new message.
34
+ * Use `create(MixinSchema)` to create a new message.
35
35
  */
36
- export const MixinDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_api, 2);
36
+ export const MixinSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_api, 2);
@@ -1,10 +1,10 @@
1
1
  import type { GenDescEnum, GenDescFile, GenDescMessage } from "../../../../../codegenv1/types.js";
2
- import type { FileDescriptorProto, GeneratedCodeInfo } from "../descriptor_pb.js";
2
+ import type { FileDescriptorProto, FileDescriptorProtoJson, GeneratedCodeInfo, GeneratedCodeInfoJson } from "../descriptor_pb.js";
3
3
  import type { Message } from "../../../../../types.js";
4
4
  /**
5
5
  * Describes the file google/protobuf/compiler/plugin.proto.
6
6
  */
7
- export declare const fileDesc_google_protobuf_compiler_plugin: GenDescFile;
7
+ export declare const file_google_protobuf_compiler_plugin: GenDescFile;
8
8
  /**
9
9
  * The version number of protocol compiler.
10
10
  *
@@ -31,11 +31,32 @@ export type Version = Message<"google.protobuf.compiler.Version"> & {
31
31
  */
32
32
  suffix: string;
33
33
  };
34
+ /**
35
+ * JSON type for the message google.protobuf.compiler.Version.
36
+ */
37
+ export type VersionJson = {
38
+ /**
39
+ * @generated from field: optional int32 major = 1;
40
+ */
41
+ major?: number;
42
+ /**
43
+ * @generated from field: optional int32 minor = 2;
44
+ */
45
+ minor?: number;
46
+ /**
47
+ * @generated from field: optional int32 patch = 3;
48
+ */
49
+ patch?: number;
50
+ /**
51
+ * @generated from field: optional string suffix = 4;
52
+ */
53
+ suffix?: string;
54
+ };
34
55
  /**
35
56
  * Describes the message google.protobuf.compiler.Version.
36
- * Use `create(VersionDesc)` to create a new message.
57
+ * Use `create(VersionSchema)` to create a new message.
37
58
  */
38
- export declare const VersionDesc: GenDescMessage<Version>;
59
+ export declare const VersionSchema: GenDescMessage<Version, VersionJson>;
39
60
  /**
40
61
  * An encoded CodeGeneratorRequest is written to the plugin's stdin.
41
62
  *
@@ -95,11 +116,36 @@ export type CodeGeneratorRequest = Message<"google.protobuf.compiler.CodeGenerat
95
116
  */
96
117
  compilerVersion?: Version;
97
118
  };
119
+ /**
120
+ * JSON type for the message google.protobuf.compiler.CodeGeneratorRequest.
121
+ */
122
+ export type CodeGeneratorRequestJson = {
123
+ /**
124
+ * @generated from field: repeated string file_to_generate = 1;
125
+ */
126
+ fileToGenerate?: string[];
127
+ /**
128
+ * @generated from field: optional string parameter = 2;
129
+ */
130
+ parameter?: string;
131
+ /**
132
+ * @generated from field: repeated google.protobuf.FileDescriptorProto proto_file = 15;
133
+ */
134
+ protoFile?: FileDescriptorProtoJson[];
135
+ /**
136
+ * @generated from field: repeated google.protobuf.FileDescriptorProto source_file_descriptors = 17;
137
+ */
138
+ sourceFileDescriptors?: FileDescriptorProtoJson[];
139
+ /**
140
+ * @generated from field: optional google.protobuf.compiler.Version compiler_version = 3;
141
+ */
142
+ compilerVersion?: VersionJson;
143
+ };
98
144
  /**
99
145
  * Describes the message google.protobuf.compiler.CodeGeneratorRequest.
100
- * Use `create(CodeGeneratorRequestDesc)` to create a new message.
146
+ * Use `create(CodeGeneratorRequestSchema)` to create a new message.
101
147
  */
102
- export declare const CodeGeneratorRequestDesc: GenDescMessage<CodeGeneratorRequest>;
148
+ export declare const CodeGeneratorRequestSchema: GenDescMessage<CodeGeneratorRequest, CodeGeneratorRequestJson>;
103
149
  /**
104
150
  * The plugin writes an encoded CodeGeneratorResponse to stdout.
105
151
  *
@@ -149,11 +195,36 @@ export type CodeGeneratorResponse = Message<"google.protobuf.compiler.CodeGenera
149
195
  */
150
196
  file: CodeGeneratorResponse_File[];
151
197
  };
198
+ /**
199
+ * JSON type for the message google.protobuf.compiler.CodeGeneratorResponse.
200
+ */
201
+ export type CodeGeneratorResponseJson = {
202
+ /**
203
+ * @generated from field: optional string error = 1;
204
+ */
205
+ error?: string;
206
+ /**
207
+ * @generated from field: optional uint64 supported_features = 2;
208
+ */
209
+ supportedFeatures?: string;
210
+ /**
211
+ * @generated from field: optional int32 minimum_edition = 3;
212
+ */
213
+ minimumEdition?: number;
214
+ /**
215
+ * @generated from field: optional int32 maximum_edition = 4;
216
+ */
217
+ maximumEdition?: number;
218
+ /**
219
+ * @generated from field: repeated google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
220
+ */
221
+ file?: CodeGeneratorResponse_FileJson[];
222
+ };
152
223
  /**
153
224
  * Describes the message google.protobuf.compiler.CodeGeneratorResponse.
154
- * Use `create(CodeGeneratorResponseDesc)` to create a new message.
225
+ * Use `create(CodeGeneratorResponseSchema)` to create a new message.
155
226
  */
156
- export declare const CodeGeneratorResponseDesc: GenDescMessage<CodeGeneratorResponse>;
227
+ export declare const CodeGeneratorResponseSchema: GenDescMessage<CodeGeneratorResponse, CodeGeneratorResponseJson>;
157
228
  /**
158
229
  * Represents a single generated file.
159
230
  *
@@ -233,11 +304,32 @@ export type CodeGeneratorResponse_File = Message<"google.protobuf.compiler.CodeG
233
304
  */
234
305
  generatedCodeInfo?: GeneratedCodeInfo;
235
306
  };
307
+ /**
308
+ * JSON type for the message google.protobuf.compiler.CodeGeneratorResponse.File.
309
+ */
310
+ export type CodeGeneratorResponse_FileJson = {
311
+ /**
312
+ * @generated from field: optional string name = 1;
313
+ */
314
+ name?: string;
315
+ /**
316
+ * @generated from field: optional string insertion_point = 2;
317
+ */
318
+ insertionPoint?: string;
319
+ /**
320
+ * @generated from field: optional string content = 15;
321
+ */
322
+ content?: string;
323
+ /**
324
+ * @generated from field: optional google.protobuf.GeneratedCodeInfo generated_code_info = 16;
325
+ */
326
+ generatedCodeInfo?: GeneratedCodeInfoJson;
327
+ };
236
328
  /**
237
329
  * Describes the message google.protobuf.compiler.CodeGeneratorResponse.File.
238
- * Use `create(CodeGeneratorResponse_FileDesc)` to create a new message.
330
+ * Use `create(CodeGeneratorResponse_FileSchema)` to create a new message.
239
331
  */
240
- export declare const CodeGeneratorResponse_FileDesc: GenDescMessage<CodeGeneratorResponse_File>;
332
+ export declare const CodeGeneratorResponse_FileSchema: GenDescMessage<CodeGeneratorResponse_File, CodeGeneratorResponse_FileJson>;
241
333
  /**
242
334
  * Sync with code_generator.h.
243
335
  *
@@ -257,7 +349,11 @@ export declare enum CodeGeneratorResponse_Feature {
257
349
  */
258
350
  SUPPORTS_EDITIONS = 2
259
351
  }
352
+ /**
353
+ * JSON type for the enum google.protobuf.compiler.CodeGeneratorResponse.Feature.
354
+ */
355
+ export type CodeGeneratorResponse_FeatureJson = "FEATURE_NONE" | "FEATURE_PROTO3_OPTIONAL" | "FEATURE_SUPPORTS_EDITIONS";
260
356
  /**
261
357
  * Describes the enum google.protobuf.compiler.CodeGeneratorResponse.Feature.
262
358
  */
263
- export declare const CodeGeneratorResponse_FeatureDesc: GenDescEnum<CodeGeneratorResponse_Feature>;
359
+ export declare const CodeGeneratorResponse_FeatureSchema: GenDescEnum<CodeGeneratorResponse_Feature, CodeGeneratorResponse_FeatureJson>;
@@ -12,33 +12,33 @@
12
12
  // See the License for the specific language governing permissions and
13
13
  // limitations under the License.
14
14
  import { fileDesc } from "../../../../../codegenv1/file.js";
15
- import { fileDesc_google_protobuf_descriptor } from "../descriptor_pb.js";
15
+ import { file_google_protobuf_descriptor } from "../descriptor_pb.js";
16
16
  import { messageDesc } from "../../../../../codegenv1/message.js";
17
17
  import { enumDesc } from "../../../../../codegenv1/enum.js";
18
18
  /**
19
19
  * Describes the file google/protobuf/compiler/plugin.proto.
20
20
  */
21
- export const fileDesc_google_protobuf_compiler_plugin = /*@__PURE__*/ fileDesc("CiVnb29nbGUvcHJvdG9idWYvY29tcGlsZXIvcGx1Z2luLnByb3RvEhhnb29nbGUucHJvdG9idWYuY29tcGlsZXIiRgoHVmVyc2lvbhINCgVtYWpvchgBIAEoBRINCgVtaW5vchgCIAEoBRINCgVwYXRjaBgDIAEoBRIOCgZzdWZmaXgYBCABKAkigQIKFENvZGVHZW5lcmF0b3JSZXF1ZXN0EhgKEGZpbGVfdG9fZ2VuZXJhdGUYASADKAkSEQoJcGFyYW1ldGVyGAIgASgJEjgKCnByb3RvX2ZpbGUYDyADKAsyJC5nb29nbGUucHJvdG9idWYuRmlsZURlc2NyaXB0b3JQcm90bxJFChdzb3VyY2VfZmlsZV9kZXNjcmlwdG9ycxgRIAMoCzIkLmdvb2dsZS5wcm90b2J1Zi5GaWxlRGVzY3JpcHRvclByb3RvEjsKEGNvbXBpbGVyX3ZlcnNpb24YAyABKAsyIS5nb29nbGUucHJvdG9idWYuY29tcGlsZXIuVmVyc2lvbiKSAwoVQ29kZUdlbmVyYXRvclJlc3BvbnNlEg0KBWVycm9yGAEgASgJEhoKEnN1cHBvcnRlZF9mZWF0dXJlcxgCIAEoBBIXCg9taW5pbXVtX2VkaXRpb24YAyABKAUSFwoPbWF4aW11bV9lZGl0aW9uGAQgASgFEkIKBGZpbGUYDyADKAsyNC5nb29nbGUucHJvdG9idWYuY29tcGlsZXIuQ29kZUdlbmVyYXRvclJlc3BvbnNlLkZpbGUafwoERmlsZRIMCgRuYW1lGAEgASgJEhcKD2luc2VydGlvbl9wb2ludBgCIAEoCRIPCgdjb250ZW50GA8gASgJEj8KE2dlbmVyYXRlZF9jb2RlX2luZm8YECABKAsyIi5nb29nbGUucHJvdG9idWYuR2VuZXJhdGVkQ29kZUluZm8iVwoHRmVhdHVyZRIQCgxGRUFUVVJFX05PTkUQABIbChdGRUFUVVJFX1BST1RPM19PUFRJT05BTBABEh0KGUZFQVRVUkVfU1VQUE9SVFNfRURJVElPTlMQAkJyChxjb20uZ29vZ2xlLnByb3RvYnVmLmNvbXBpbGVyQgxQbHVnaW5Qcm90b3NaKWdvb2dsZS5nb2xhbmcub3JnL3Byb3RvYnVmL3R5cGVzL3BsdWdpbnBiqgIYR29vZ2xlLlByb3RvYnVmLkNvbXBpbGVy", [fileDesc_google_protobuf_descriptor]);
21
+ export const file_google_protobuf_compiler_plugin = /*@__PURE__*/ fileDesc("CiVnb29nbGUvcHJvdG9idWYvY29tcGlsZXIvcGx1Z2luLnByb3RvEhhnb29nbGUucHJvdG9idWYuY29tcGlsZXIiRgoHVmVyc2lvbhINCgVtYWpvchgBIAEoBRINCgVtaW5vchgCIAEoBRINCgVwYXRjaBgDIAEoBRIOCgZzdWZmaXgYBCABKAkigQIKFENvZGVHZW5lcmF0b3JSZXF1ZXN0EhgKEGZpbGVfdG9fZ2VuZXJhdGUYASADKAkSEQoJcGFyYW1ldGVyGAIgASgJEjgKCnByb3RvX2ZpbGUYDyADKAsyJC5nb29nbGUucHJvdG9idWYuRmlsZURlc2NyaXB0b3JQcm90bxJFChdzb3VyY2VfZmlsZV9kZXNjcmlwdG9ycxgRIAMoCzIkLmdvb2dsZS5wcm90b2J1Zi5GaWxlRGVzY3JpcHRvclByb3RvEjsKEGNvbXBpbGVyX3ZlcnNpb24YAyABKAsyIS5nb29nbGUucHJvdG9idWYuY29tcGlsZXIuVmVyc2lvbiKSAwoVQ29kZUdlbmVyYXRvclJlc3BvbnNlEg0KBWVycm9yGAEgASgJEhoKEnN1cHBvcnRlZF9mZWF0dXJlcxgCIAEoBBIXCg9taW5pbXVtX2VkaXRpb24YAyABKAUSFwoPbWF4aW11bV9lZGl0aW9uGAQgASgFEkIKBGZpbGUYDyADKAsyNC5nb29nbGUucHJvdG9idWYuY29tcGlsZXIuQ29kZUdlbmVyYXRvclJlc3BvbnNlLkZpbGUafwoERmlsZRIMCgRuYW1lGAEgASgJEhcKD2luc2VydGlvbl9wb2ludBgCIAEoCRIPCgdjb250ZW50GA8gASgJEj8KE2dlbmVyYXRlZF9jb2RlX2luZm8YECABKAsyIi5nb29nbGUucHJvdG9idWYuR2VuZXJhdGVkQ29kZUluZm8iVwoHRmVhdHVyZRIQCgxGRUFUVVJFX05PTkUQABIbChdGRUFUVVJFX1BST1RPM19PUFRJT05BTBABEh0KGUZFQVRVUkVfU1VQUE9SVFNfRURJVElPTlMQAkJyChxjb20uZ29vZ2xlLnByb3RvYnVmLmNvbXBpbGVyQgxQbHVnaW5Qcm90b3NaKWdvb2dsZS5nb2xhbmcub3JnL3Byb3RvYnVmL3R5cGVzL3BsdWdpbnBiqgIYR29vZ2xlLlByb3RvYnVmLkNvbXBpbGVy", [file_google_protobuf_descriptor]);
22
22
  /**
23
23
  * Describes the message google.protobuf.compiler.Version.
24
- * Use `create(VersionDesc)` to create a new message.
24
+ * Use `create(VersionSchema)` to create a new message.
25
25
  */
26
- export const VersionDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_compiler_plugin, 0);
26
+ export const VersionSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_compiler_plugin, 0);
27
27
  /**
28
28
  * Describes the message google.protobuf.compiler.CodeGeneratorRequest.
29
- * Use `create(CodeGeneratorRequestDesc)` to create a new message.
29
+ * Use `create(CodeGeneratorRequestSchema)` to create a new message.
30
30
  */
31
- export const CodeGeneratorRequestDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_compiler_plugin, 1);
31
+ export const CodeGeneratorRequestSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_compiler_plugin, 1);
32
32
  /**
33
33
  * Describes the message google.protobuf.compiler.CodeGeneratorResponse.
34
- * Use `create(CodeGeneratorResponseDesc)` to create a new message.
34
+ * Use `create(CodeGeneratorResponseSchema)` to create a new message.
35
35
  */
36
- export const CodeGeneratorResponseDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_compiler_plugin, 2);
36
+ export const CodeGeneratorResponseSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_compiler_plugin, 2);
37
37
  /**
38
38
  * Describes the message google.protobuf.compiler.CodeGeneratorResponse.File.
39
- * Use `create(CodeGeneratorResponse_FileDesc)` to create a new message.
39
+ * Use `create(CodeGeneratorResponse_FileSchema)` to create a new message.
40
40
  */
41
- export const CodeGeneratorResponse_FileDesc = /*@__PURE__*/ messageDesc(fileDesc_google_protobuf_compiler_plugin, 2, 0);
41
+ export const CodeGeneratorResponse_FileSchema = /*@__PURE__*/ messageDesc(file_google_protobuf_compiler_plugin, 2, 0);
42
42
  /**
43
43
  * Sync with code_generator.h.
44
44
  *
@@ -62,4 +62,4 @@ export var CodeGeneratorResponse_Feature;
62
62
  /**
63
63
  * Describes the enum google.protobuf.compiler.CodeGeneratorResponse.Feature.
64
64
  */
65
- export const CodeGeneratorResponse_FeatureDesc = /*@__PURE__*/ enumDesc(fileDesc_google_protobuf_compiler_plugin, 2, 0);
65
+ export const CodeGeneratorResponse_FeatureSchema = /*@__PURE__*/ enumDesc(file_google_protobuf_compiler_plugin, 2, 0);