Debian Codegraph @

node/@bufbuild/protobuf/dist/esm/descriptors.js

raw
1 // Copyright 2021-2026 Buf Technologies, Inc.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 /**
15 * Scalar value types. This is a subset of field types declared by protobuf
16 * enum google.protobuf.FieldDescriptorProto.Type The types GROUP and MESSAGE
17 * are omitted, but the numerical values are identical.
18 */
19 export var ScalarType;
20 (function (ScalarType) {
21 // 0 is reserved for errors.
22 // Order is weird for historical reasons.
23 ScalarType[ScalarType["DOUBLE"] = 1] = "DOUBLE";
24 ScalarType[ScalarType["FLOAT"] = 2] = "FLOAT";
25 // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if
26 // negative values are likely.
27 ScalarType[ScalarType["INT64"] = 3] = "INT64";
28 ScalarType[ScalarType["UINT64"] = 4] = "UINT64";
29 // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if
30 // negative values are likely.
31 ScalarType[ScalarType["INT32"] = 5] = "INT32";
32 ScalarType[ScalarType["FIXED64"] = 6] = "FIXED64";
33 ScalarType[ScalarType["FIXED32"] = 7] = "FIXED32";
34 ScalarType[ScalarType["BOOL"] = 8] = "BOOL";
35 ScalarType[ScalarType["STRING"] = 9] = "STRING";
36 // Tag-delimited aggregate.
37 // Group type is deprecated and not supported in proto3. However, Proto3
38 // implementations should still be able to parse the group wire format and
39 // treat group fields as unknown fields.
40 // TYPE_GROUP = 10,
41 // TYPE_MESSAGE = 11, // Length-delimited aggregate.
42 // New in version 2.
43 ScalarType[ScalarType["BYTES"] = 12] = "BYTES";
44 ScalarType[ScalarType["UINT32"] = 13] = "UINT32";
45 // TYPE_ENUM = 14,
46 ScalarType[ScalarType["SFIXED32"] = 15] = "SFIXED32";
47 ScalarType[ScalarType["SFIXED64"] = 16] = "SFIXED64";
48 ScalarType[ScalarType["SINT32"] = 17] = "SINT32";
49 ScalarType[ScalarType["SINT64"] = 18] = "SINT64";
50 })(ScalarType || (ScalarType = {}));