diff options
Diffstat (limited to 'frontend-old/node_modules/@grpc/proto-loader')
11 files changed, 1846 insertions, 0 deletions
diff --git a/frontend-old/node_modules/@grpc/proto-loader/LICENSE b/frontend-old/node_modules/@grpc/proto-loader/LICENSE new file mode 100644 index 0000000..8dada3e --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright {yyyy} {name of copyright owner} + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/frontend-old/node_modules/@grpc/proto-loader/README.md b/frontend-old/node_modules/@grpc/proto-loader/README.md new file mode 100644 index 0000000..935c100 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/README.md @@ -0,0 +1,140 @@ +# gRPC Protobuf Loader + +A utility package for loading `.proto` files for use with gRPC, using the latest Protobuf.js package. +Please refer to [protobuf.js' documentation](https://github.com/dcodeIO/protobuf.js/blob/master/README.md) +to understands its features and limitations. + +## Installation + +```sh +npm install @grpc/proto-loader +``` + +## Usage + +```js +const protoLoader = require('@grpc/proto-loader'); +const grpcLibrary = require('grpc'); +// OR +const grpcLibrary = require('@grpc/grpc-js'); + +protoLoader.load(protoFileName, options).then(packageDefinition => { + const packageObject = grpcLibrary.loadPackageDefinition(packageDefinition); +}); +// OR +const packageDefinition = protoLoader.loadSync(protoFileName, options); +const packageObject = grpcLibrary.loadPackageDefinition(packageDefinition); +``` + +The options parameter is an object that can have the following optional properties: + +| Field name | Valid values | Description +|------------|--------------|------------ +| `keepCase` | `true` or `false` | Preserve field names. The default is to change them to camel case. +| `longs` | `String` or `Number` | The type to use to represent `long` values. Defaults to a `Long` object type. +| `enums` | `String` | The type to use to represent `enum` values. Defaults to the numeric value. +| `bytes` | `Array` or `String` | The type to use to represent `bytes` values. Defaults to `Buffer`. +| `defaults` | `true` or `false` | Set default values on output objects. Defaults to `false`. +| `arrays` | `true` or `false` | Set empty arrays for missing array values even if `defaults` is `false` Defaults to `false`. +| `objects` | `true` or `false` | Set empty objects for missing object values even if `defaults` is `false` Defaults to `false`. +| `oneofs` | `true` or `false` | Set virtual oneof properties to the present field's name. Defaults to `false`. +| `json` | `true` or `false` | Represent `Infinity` and `NaN` as strings in `float` fields, and automatically decode `google.protobuf.Any` values. Defaults to `false` +| `includeDirs` | An array of strings | A list of search paths for imported `.proto` files. + +The following options object closely approximates the existing behavior of `grpc.load`: + +```js +const options = { + keepCase: true, + longs: String, + enums: String, + defaults: true, + oneofs: true +} +``` + +## Generating TypeScript types + +The `proto-loader-gen-types` script distributed with this package can be used to generate TypeScript type information for the objects loaded at runtime. More information about how to use it can be found in [the *@grpc/proto-loader TypeScript Type Generator CLI Tool* proposal document](https://github.com/grpc/proposal/blob/master/L70-node-proto-loader-type-generator.md). The arguments mostly match the `load` function's options; the full usage information is as follows: + +```console +proto-loader-gen-types.js [options] filenames... + +Options: + --help Show help [boolean] + --version Show version number [boolean] + --keepCase Preserve the case of field names + [boolean] [default: false] + --longs The type that should be used to output 64 bit + integer values. Can be String, Number + [string] [default: "Long"] + --enums The type that should be used to output enum fields. + Can be String [string] [default: "number"] + --bytes The type that should be used to output bytes + fields. Can be String, Array + [string] [default: "Buffer"] + --defaults Output default values for omitted fields + [boolean] [default: false] + --arrays Output default values for omitted repeated fields + even if --defaults is not set + [boolean] [default: false] + --objects Output default values for omitted message fields + even if --defaults is not set + [boolean] [default: false] + --oneofs Output virtual oneof fields set to the present + field's name [boolean] [default: false] + --json Represent Infinity and NaN as strings in float + fields. Also decode google.protobuf.Any + automatically [boolean] [default: false] + --includeComments Generate doc comments from comments in the original + files [boolean] [default: false] + -I, --includeDirs Directories to search for included files [array] + -O, --outDir Directory in which to output files + [string] [required] + --grpcLib The gRPC implementation library that these types + will be used with. If not provided, some types will + not be generated [string] + --inputTemplate Template for mapping input or "permissive" type + names [string] [default: "%s"] + --outputTemplate Template for mapping output or "restricted" type + names [string] [default: "%s__Output"] + --inputBranded Output property for branded type for "permissive" + types with fullName of the Message as its value + [boolean] [default: false] + --outputBranded Output property for branded type for "restricted" + types with fullName of the Message as its value + [boolean] [default: false] + --targetFileExtension File extension for generated files. + [string] [default: ".ts"] + --importFileExtension File extension for import specifiers in generated + code. [string] [default: ""] +``` + +### Example Usage + +Generate the types: + +```sh +$(npm bin)/proto-loader-gen-types --longs=String --enums=String --defaults --oneofs --grpcLib=@grpc/grpc-js --outDir=proto/ proto/*.proto +``` + +Consume the types: + +```ts +import * as grpc from '@grpc/grpc-js'; +import * as protoLoader from '@grpc/proto-loader'; +import type { ProtoGrpcType } from './proto/example.ts'; +import type { ExampleHandlers } from './proto/example_package/Example.ts'; + +const exampleServer: ExampleHandlers = { + // server handlers implementation... +}; + +const packageDefinition = protoLoader.loadSync('./proto/example.proto'); +const proto = (grpc.loadPackageDefinition( + packageDefinition +) as unknown) as ProtoGrpcType; + +const server = new grpc.Server(); +server.addService(proto.example_package.Example.service, exampleServer); +``` diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js b/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js new file mode 100755 index 0000000..1df55f7 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js @@ -0,0 +1,913 @@ +#!/usr/bin/env node +"use strict"; +/** + * @license + * Copyright 2020 gRPC authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +Object.defineProperty(exports, "__esModule", { value: true }); +const fs = require("fs"); +const path = require("path"); +const Protobuf = require("protobufjs"); +const yargs = require("yargs"); +const camelCase = require("lodash.camelcase"); +const util_1 = require("../src/util"); +const templateStr = "%s"; +const useNameFmter = ({ outputTemplate, inputTemplate }) => { + if (outputTemplate === inputTemplate) { + throw new Error('inputTemplate and outputTemplate must differ'); + } + return { + outputName: (n) => outputTemplate.replace(templateStr, n), + inputName: (n) => inputTemplate.replace(templateStr, n) + }; +}; +class TextFormatter { + constructor() { + this.indentText = ' '; + this.indentValue = 0; + this.textParts = []; + } + indent() { + this.indentValue += 1; + } + unindent() { + this.indentValue -= 1; + } + writeLine(line) { + for (let i = 0; i < this.indentValue; i += 1) { + this.textParts.push(this.indentText); + } + this.textParts.push(line); + this.textParts.push('\n'); + } + getFullText() { + return this.textParts.join(''); + } +} +// GENERATOR UTILITY FUNCTIONS +function compareName(x, y) { + if (x.name < y.name) { + return -1; + } + else if (x.name > y.name) { + return 1; + } + else { + return 0; + } +} +function isNamespaceBase(obj) { + return Array.isArray(obj.nestedArray); +} +function stripLeadingPeriod(name) { + return name.startsWith('.') ? name.substring(1) : name; +} +function getImportPath(to) { + /* If the thing we are importing is defined in a message, it is generated in + * the same file as that message. */ + if (to.parent instanceof Protobuf.Type) { + return getImportPath(to.parent); + } + return stripLeadingPeriod(to.fullName).replace(/\./g, '/'); +} +function getPath(to, options) { + return stripLeadingPeriod(to.fullName).replace(/\./g, '/') + options.targetFileExtension; +} +function getPathToRoot(from) { + const depth = stripLeadingPeriod(from.fullName).split('.').length - 1; + if (depth === 0) { + return './'; + } + let path = ''; + for (let i = 0; i < depth; i++) { + path += '../'; + } + return path; +} +function getRelativeImportPath(from, to) { + return getPathToRoot(from) + getImportPath(to); +} +function getTypeInterfaceName(type) { + return type.fullName.replace(/\./g, '_'); +} +function getImportLine(dependency, from, options) { + const filePath = from === undefined ? './' + getImportPath(dependency) : getRelativeImportPath(from, dependency); + const { outputName, inputName } = useNameFmter(options); + const typeInterfaceName = getTypeInterfaceName(dependency); + let importedTypes; + /* If the dependency is defined within a message, it will be generated in that + * message's file and exported using its typeInterfaceName. */ + if (dependency.parent instanceof Protobuf.Type) { + if (dependency instanceof Protobuf.Type || dependency instanceof Protobuf.Enum) { + importedTypes = `${inputName(typeInterfaceName)}, ${outputName(typeInterfaceName)}`; + } + else if (dependency instanceof Protobuf.Service) { + importedTypes = `${typeInterfaceName}Client, ${typeInterfaceName}Definition`; + } + else { + throw new Error('Invalid object passed to getImportLine'); + } + } + else { + if (dependency instanceof Protobuf.Type || dependency instanceof Protobuf.Enum) { + importedTypes = `${inputName(dependency.name)} as ${inputName(typeInterfaceName)}, ${outputName(dependency.name)} as ${outputName(typeInterfaceName)}`; + } + else if (dependency instanceof Protobuf.Service) { + importedTypes = `${dependency.name}Client as ${typeInterfaceName}Client, ${dependency.name}Definition as ${typeInterfaceName}Definition`; + } + else { + throw new Error('Invalid object passed to getImportLine'); + } + } + return `import type { ${importedTypes} } from '${filePath}${options.importFileExtension}';`; +} +function getChildMessagesAndEnums(namespace) { + const messageList = []; + for (const nested of namespace.nestedArray) { + if (nested instanceof Protobuf.Type || nested instanceof Protobuf.Enum) { + messageList.push(nested); + } + if (isNamespaceBase(nested)) { + messageList.push(...getChildMessagesAndEnums(nested)); + } + } + return messageList; +} +function formatComment(formatter, comment, options) { + if (!comment && !(options === null || options === void 0 ? void 0 : options.deprecated)) { + return; + } + formatter.writeLine('/**'); + if (comment) { + for (const line of comment.split('\n')) { + formatter.writeLine(` * ${line.replace(/\*\//g, '* /')}`); + } + } + if (options === null || options === void 0 ? void 0 : options.deprecated) { + formatter.writeLine(' * @deprecated'); + } + formatter.writeLine(' */'); +} +const typeBrandHint = `This field is a type brand and is not populated at runtime. Instances of this type should be created using type assertions. +https://github.com/grpc/grpc-node/pull/2281`; +function formatTypeBrand(formatter, messageType) { + formatComment(formatter, typeBrandHint); + formatter.writeLine(`__type: '${messageType.fullName}'`); +} +// GENERATOR FUNCTIONS +function getTypeNamePermissive(fieldType, resolvedType, repeated, map, options) { + const { inputName } = useNameFmter(options); + switch (fieldType) { + case 'double': + case 'float': + return 'number | string'; + case 'int32': + case 'uint32': + case 'sint32': + case 'fixed32': + case 'sfixed32': + return 'number'; + case 'int64': + case 'uint64': + case 'sint64': + case 'fixed64': + case 'sfixed64': + return 'number | string | Long'; + case 'bool': + return 'boolean'; + case 'string': + return 'string'; + case 'bytes': + return 'Buffer | Uint8Array | string'; + default: + if (resolvedType === null) { + throw new Error('Found field with no usable type'); + } + const typeInterfaceName = getTypeInterfaceName(resolvedType); + if (resolvedType instanceof Protobuf.Type) { + if (repeated || map) { + return inputName(typeInterfaceName); + } + else { + return `${inputName(typeInterfaceName)} | null`; + } + } + else { + // Enum + return inputName(typeInterfaceName); + } + } +} +function getFieldTypePermissive(field, options) { + const valueType = getTypeNamePermissive(field.type, field.resolvedType, field.repeated, field.map, options); + if (field instanceof Protobuf.MapField) { + const keyType = field.keyType === 'string' ? 'string' : 'number'; + return `{[key: ${keyType}]: ${valueType}}`; + } + else { + return valueType; + } +} +function generatePermissiveMessageInterface(formatter, messageType, options, nameOverride) { + const { inputName } = useNameFmter(options); + if (options.includeComments) { + formatComment(formatter, messageType.comment, messageType.options); + } + if (messageType.fullName === '.google.protobuf.Any') { + /* This describes the behavior of the Protobuf.js Any wrapper fromObject + * replacement function */ + formatter.writeLine(`export type ${inputName('Any')} = AnyExtension | {`); + formatter.writeLine(' type_url: string;'); + formatter.writeLine(' value: Buffer | Uint8Array | string;'); + formatter.writeLine('}'); + return; + } + formatter.writeLine(`export interface ${inputName(nameOverride !== null && nameOverride !== void 0 ? nameOverride : messageType.name)} {`); + formatter.indent(); + for (const field of messageType.fieldsArray) { + const repeatedString = field.repeated ? '[]' : ''; + const type = getFieldTypePermissive(field, options); + if (options.includeComments) { + formatComment(formatter, field.comment, field.options); + } + formatter.writeLine(`'${field.name}'?: (${type})${repeatedString};`); + } + for (const oneof of messageType.oneofsArray) { + const typeString = oneof.fieldsArray.map(field => `"${field.name}"`).join('|'); + if (options.includeComments) { + formatComment(formatter, oneof.comment, oneof.options); + } + formatter.writeLine(`'${oneof.name}'?: ${typeString};`); + } + if (options.inputBranded) { + formatTypeBrand(formatter, messageType); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function getTypeNameRestricted(fieldType, resolvedType, repeated, map, options) { + const { outputName } = useNameFmter(options); + switch (fieldType) { + case 'double': + case 'float': + if (options.json) { + return 'number | string'; + } + else { + return 'number'; + } + case 'int32': + case 'uint32': + case 'sint32': + case 'fixed32': + case 'sfixed32': + return 'number'; + case 'int64': + case 'uint64': + case 'sint64': + case 'fixed64': + case 'sfixed64': + if (options.longs === Number) { + return 'number'; + } + else if (options.longs === String) { + return 'string'; + } + else { + return 'Long'; + } + case 'bool': + return 'boolean'; + case 'string': + return 'string'; + case 'bytes': + if (options.bytes === Array) { + return 'Uint8Array'; + } + else if (options.bytes === String) { + return 'string'; + } + else { + return 'Buffer'; + } + default: + if (resolvedType === null) { + throw new Error('Found field with no usable type'); + } + const typeInterfaceName = getTypeInterfaceName(resolvedType); + if (resolvedType instanceof Protobuf.Type) { + /* null is only used to represent absent message values if the defaults + * option is set, and only for non-repeated, non-map fields. */ + if (options.defaults && !repeated && !map) { + return `${outputName(typeInterfaceName)} | null`; + } + else { + return `${outputName(typeInterfaceName)}`; + } + } + else { + // Enum + return outputName(typeInterfaceName); + } + } +} +function getFieldTypeRestricted(field, options) { + const valueType = getTypeNameRestricted(field.type, field.resolvedType, field.repeated, field.map, options); + if (field instanceof Protobuf.MapField) { + const keyType = field.keyType === 'string' ? 'string' : 'number'; + return `{[key: ${keyType}]: ${valueType}}`; + } + else { + return valueType; + } +} +function generateRestrictedMessageInterface(formatter, messageType, options, nameOverride) { + var _a, _b, _c; + const { outputName } = useNameFmter(options); + if (options.includeComments) { + formatComment(formatter, messageType.comment, messageType.options); + } + if (messageType.fullName === '.google.protobuf.Any' && options.json) { + /* This describes the behavior of the Protobuf.js Any wrapper toObject + * replacement function */ + let optionalString = options.defaults ? '' : '?'; + formatter.writeLine(`export type ${outputName('Any')} = AnyExtension | {`); + formatter.writeLine(` type_url${optionalString}: string;`); + formatter.writeLine(` value${optionalString}: ${getTypeNameRestricted('bytes', null, false, false, options)};`); + formatter.writeLine('}'); + return; + } + formatter.writeLine(`export interface ${outputName(nameOverride !== null && nameOverride !== void 0 ? nameOverride : messageType.name)} {`); + formatter.indent(); + for (const field of messageType.fieldsArray) { + let fieldGuaranteed; + if (field.partOf) { + // The field is not guaranteed populated if it is part of a oneof + fieldGuaranteed = false; + } + else if (field.repeated) { + fieldGuaranteed = (_a = (options.defaults || options.arrays)) !== null && _a !== void 0 ? _a : false; + } + else if (field.map) { + fieldGuaranteed = (_b = (options.defaults || options.objects)) !== null && _b !== void 0 ? _b : false; + } + else { + fieldGuaranteed = (_c = options.defaults) !== null && _c !== void 0 ? _c : false; + } + const optionalString = fieldGuaranteed ? '' : '?'; + const repeatedString = field.repeated ? '[]' : ''; + const type = getFieldTypeRestricted(field, options); + if (options.includeComments) { + formatComment(formatter, field.comment, field.options); + } + formatter.writeLine(`'${field.name}'${optionalString}: (${type})${repeatedString};`); + } + if (options.oneofs) { + for (const oneof of messageType.oneofsArray) { + const typeString = oneof.fieldsArray.map(field => `"${field.name}"`).join('|'); + if (options.includeComments) { + formatComment(formatter, oneof.comment, oneof.options); + } + formatter.writeLine(`'${oneof.name}'?: ${typeString};`); + } + } + if (options.outputBranded) { + formatTypeBrand(formatter, messageType); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function generateMessageInterfaces(formatter, messageType, options) { + var _a, _b; + let usesLong = false; + let seenDeps = new Set(); + const childTypes = getChildMessagesAndEnums(messageType); + formatter.writeLine(`// Original file: ${(_b = ((_a = messageType.filename) !== null && _a !== void 0 ? _a : 'null')) === null || _b === void 0 ? void 0 : _b.replace(/\\/g, '/')}`); + formatter.writeLine(''); + const isLongField = (field) => ['int64', 'uint64', 'sint64', 'fixed64', 'sfixed64'].includes(field.type); + messageType.fieldsArray.sort((fieldA, fieldB) => fieldA.id - fieldB.id); + for (const field of messageType.fieldsArray) { + if (field.resolvedType && childTypes.indexOf(field.resolvedType) < 0) { + const dependency = field.resolvedType; + if (seenDeps.has(dependency.fullName)) { + continue; + } + seenDeps.add(dependency.fullName); + formatter.writeLine(getImportLine(dependency, messageType, options)); + } + if (isLongField(field)) { + usesLong = true; + } + } + for (const childType of childTypes) { + if (childType instanceof Protobuf.Type) { + for (const field of childType.fieldsArray) { + if (field.resolvedType && childTypes.indexOf(field.resolvedType) < 0) { + const dependency = field.resolvedType; + if (seenDeps.has(dependency.fullName)) { + continue; + } + seenDeps.add(dependency.fullName); + formatter.writeLine(getImportLine(dependency, messageType, options)); + } + if (isLongField(field)) { + usesLong = true; + } + } + } + } + if (usesLong) { + formatter.writeLine("import type { Long } from '@grpc/proto-loader';"); + } + if (messageType.fullName === '.google.protobuf.Any') { + formatter.writeLine("import type { AnyExtension } from '@grpc/proto-loader';"); + } + formatter.writeLine(''); + for (const childType of childTypes.sort(compareName)) { + const nameOverride = getTypeInterfaceName(childType); + if (childType instanceof Protobuf.Type) { + generatePermissiveMessageInterface(formatter, childType, options, nameOverride); + formatter.writeLine(''); + generateRestrictedMessageInterface(formatter, childType, options, nameOverride); + } + else { + generateEnumInterface(formatter, childType, options, nameOverride); + } + formatter.writeLine(''); + } + generatePermissiveMessageInterface(formatter, messageType, options); + formatter.writeLine(''); + generateRestrictedMessageInterface(formatter, messageType, options); +} +function generateEnumInterface(formatter, enumType, options, nameOverride) { + var _a, _b, _c; + const { inputName, outputName } = useNameFmter(options); + const name = nameOverride !== null && nameOverride !== void 0 ? nameOverride : enumType.name; + formatter.writeLine(`// Original file: ${(_b = ((_a = enumType.filename) !== null && _a !== void 0 ? _a : 'null')) === null || _b === void 0 ? void 0 : _b.replace(/\\/g, '/')}`); + formatter.writeLine(''); + if (options.includeComments) { + formatComment(formatter, enumType.comment, enumType.options); + } + formatter.writeLine(`export const ${name} = {`); + formatter.indent(); + for (const key of Object.keys(enumType.values)) { + if (options.includeComments) { + formatComment(formatter, enumType.comments[key], ((_c = enumType.valuesOptions) !== null && _c !== void 0 ? _c : {})[key]); + } + formatter.writeLine(`${key}: ${options.enums == String ? `'${key}'` : enumType.values[key]},`); + } + formatter.unindent(); + formatter.writeLine('} as const;'); + // Permissive Type + formatter.writeLine(''); + if (options.includeComments) { + formatComment(formatter, enumType.comment, enumType.options); + } + formatter.writeLine(`export type ${inputName(name)} =`); + formatter.indent(); + for (const key of Object.keys(enumType.values)) { + if (options.includeComments) { + formatComment(formatter, enumType.comments[key]); + } + formatter.writeLine(`| '${key}'`); + formatter.writeLine(`| ${enumType.values[key]}`); + } + formatter.unindent(); + // Restrictive Type + formatter.writeLine(''); + if (options.includeComments) { + formatComment(formatter, enumType.comment, enumType.options); + } + formatter.writeLine(`export type ${outputName(name)} = typeof ${name}[keyof typeof ${name}]`); +} +/** + * This is a list of methods that are exist in the generic Client class in the + * gRPC libraries. TypeScript has a problem with methods in subclasses with the + * same names as methods in the superclass, but with mismatched APIs. So, we + * avoid generating methods with these names in the service client interfaces. + * We always generate two service client methods per service method: one camel + * cased, and one with the original casing. So we will still generate one + * service client method for any conflicting name. + * + * Technically, at runtime conflicting name in the service client method + * actually shadows the original method, but TypeScript does not have a good + * way to represent that. So this change is not 100% accurate, but it gets the + * generated code to compile. + * + * This is just a list of the methods in the Client class definitions in + * grpc@1.24.11 and @grpc/grpc-js@1.4.0. + */ +const CLIENT_RESERVED_METHOD_NAMES = new Set([ + 'close', + 'getChannel', + 'waitForReady', + 'makeUnaryRequest', + 'makeClientStreamRequest', + 'makeServerStreamRequest', + 'makeBidiStreamRequest', + 'resolveCallInterceptors', + /* These methods are private, but TypeScript is not happy with overriding even + * private methods with mismatched APIs. */ + 'checkOptionalUnaryResponseArguments', + 'checkMetadataAndOptions' +]); +function generateServiceClientInterface(formatter, serviceType, options) { + const { outputName, inputName } = useNameFmter(options); + if (options.includeComments) { + formatComment(formatter, serviceType.comment, serviceType.options); + } + formatter.writeLine(`export interface ${serviceType.name}Client extends grpc.Client {`); + formatter.indent(); + for (const methodName of Object.keys(serviceType.methods).sort()) { + const method = serviceType.methods[methodName]; + for (const name of new Set([methodName, camelCase(methodName)])) { + if (CLIENT_RESERVED_METHOD_NAMES.has(name)) { + continue; + } + if (options.includeComments) { + formatComment(formatter, method.comment, method.options); + } + const requestType = inputName(getTypeInterfaceName(method.resolvedRequestType)); + const responseType = outputName(getTypeInterfaceName(method.resolvedResponseType)); + const callbackType = `grpc.requestCallback<${responseType}>`; + if (method.requestStream) { + if (method.responseStream) { + // Bidi streaming + const callType = `grpc.ClientDuplexStream<${requestType}, ${responseType}>`; + formatter.writeLine(`${name}(metadata: grpc.Metadata, options?: grpc.CallOptions): ${callType};`); + formatter.writeLine(`${name}(options?: grpc.CallOptions): ${callType};`); + } + else { + // Client streaming + const callType = `grpc.ClientWritableStream<${requestType}>`; + formatter.writeLine(`${name}(metadata: grpc.Metadata, options: grpc.CallOptions, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(metadata: grpc.Metadata, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(options: grpc.CallOptions, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(callback: ${callbackType}): ${callType};`); + } + } + else { + if (method.responseStream) { + // Server streaming + const callType = `grpc.ClientReadableStream<${responseType}>`; + formatter.writeLine(`${name}(argument: ${requestType}, metadata: grpc.Metadata, options?: grpc.CallOptions): ${callType};`); + formatter.writeLine(`${name}(argument: ${requestType}, options?: grpc.CallOptions): ${callType};`); + } + else { + // Unary + const callType = 'grpc.ClientUnaryCall'; + formatter.writeLine(`${name}(argument: ${requestType}, metadata: grpc.Metadata, options: grpc.CallOptions, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(argument: ${requestType}, metadata: grpc.Metadata, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(argument: ${requestType}, options: grpc.CallOptions, callback: ${callbackType}): ${callType};`); + formatter.writeLine(`${name}(argument: ${requestType}, callback: ${callbackType}): ${callType};`); + } + } + } + formatter.writeLine(''); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function generateServiceHandlerInterface(formatter, serviceType, options) { + const { inputName, outputName } = useNameFmter(options); + if (options.includeComments) { + formatComment(formatter, serviceType.comment, serviceType.options); + } + formatter.writeLine(`export interface ${serviceType.name}Handlers extends grpc.UntypedServiceImplementation {`); + formatter.indent(); + for (const methodName of Object.keys(serviceType.methods).sort()) { + const method = serviceType.methods[methodName]; + if (options.includeComments) { + formatComment(formatter, method.comment, serviceType.options); + } + const requestType = outputName(getTypeInterfaceName(method.resolvedRequestType)); + const responseType = inputName(getTypeInterfaceName(method.resolvedResponseType)); + if (method.requestStream) { + if (method.responseStream) { + // Bidi streaming + formatter.writeLine(`${methodName}: grpc.handleBidiStreamingCall<${requestType}, ${responseType}>;`); + } + else { + // Client streaming + formatter.writeLine(`${methodName}: grpc.handleClientStreamingCall<${requestType}, ${responseType}>;`); + } + } + else { + if (method.responseStream) { + // Server streaming + formatter.writeLine(`${methodName}: grpc.handleServerStreamingCall<${requestType}, ${responseType}>;`); + } + else { + // Unary + formatter.writeLine(`${methodName}: grpc.handleUnaryCall<${requestType}, ${responseType}>;`); + } + } + formatter.writeLine(''); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function generateServiceDefinitionInterface(formatter, serviceType, options) { + const { inputName, outputName } = useNameFmter(options); + if (options.grpcLib) { + formatter.writeLine(`export interface ${serviceType.name}Definition extends grpc.ServiceDefinition {`); + } + else { + formatter.writeLine(`export interface ${serviceType.name}Definition {`); + } + formatter.indent(); + for (const methodName of Object.keys(serviceType.methods).sort()) { + const method = serviceType.methods[methodName]; + const requestType = getTypeInterfaceName(method.resolvedRequestType); + const responseType = getTypeInterfaceName(method.resolvedResponseType); + formatter.writeLine(`${methodName}: MethodDefinition<${inputName(requestType)}, ${inputName(responseType)}, ${outputName(requestType)}, ${outputName(responseType)}>`); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function generateServiceInterfaces(formatter, serviceType, options) { + var _a, _b; + formatter.writeLine(`// Original file: ${(_b = ((_a = serviceType.filename) !== null && _a !== void 0 ? _a : 'null')) === null || _b === void 0 ? void 0 : _b.replace(/\\/g, '/')}`); + formatter.writeLine(''); + if (options.grpcLib) { + const grpcImportPath = options.grpcLib.startsWith('.') ? getPathToRoot(serviceType) + options.grpcLib : options.grpcLib; + formatter.writeLine(`import type * as grpc from '${grpcImportPath}'`); + } + formatter.writeLine(`import type { MethodDefinition } from '@grpc/proto-loader'`); + const dependencies = new Set(); + for (const method of serviceType.methodsArray) { + dependencies.add(method.resolvedRequestType); + dependencies.add(method.resolvedResponseType); + } + for (const dep of Array.from(dependencies.values()).sort(compareName)) { + formatter.writeLine(getImportLine(dep, serviceType, options)); + } + formatter.writeLine(''); + if (options.grpcLib) { + generateServiceClientInterface(formatter, serviceType, options); + formatter.writeLine(''); + generateServiceHandlerInterface(formatter, serviceType, options); + formatter.writeLine(''); + } + generateServiceDefinitionInterface(formatter, serviceType, options); +} +function containsDefinition(definitionType, namespace) { + for (const nested of namespace.nestedArray.sort(compareName)) { + if (nested instanceof definitionType) { + return true; + } + else if (isNamespaceBase(nested) && !(nested instanceof Protobuf.Type) && !(nested instanceof Protobuf.Enum) && containsDefinition(definitionType, nested)) { + return true; + } + } + return false; +} +function generateDefinitionImports(formatter, namespace, options) { + const imports = []; + if (containsDefinition(Protobuf.Enum, namespace)) { + imports.push('EnumTypeDefinition'); + } + if (containsDefinition(Protobuf.Type, namespace)) { + imports.push('MessageTypeDefinition'); + } + if (imports.length) { + formatter.writeLine(`import type { ${imports.join(', ')} } from '@grpc/proto-loader';`); + } +} +function generateServiceImports(formatter, namespace, options) { + for (const nested of namespace.nestedArray.sort(compareName)) { + if (nested instanceof Protobuf.Service) { + formatter.writeLine(getImportLine(nested, undefined, options)); + } + else if (isNamespaceBase(nested) && !(nested instanceof Protobuf.Type) && !(nested instanceof Protobuf.Enum)) { + generateServiceImports(formatter, nested, options); + } + } +} +function generateSingleLoadedDefinitionType(formatter, nested, options) { + if (nested instanceof Protobuf.Service) { + if (options.includeComments) { + formatComment(formatter, nested.comment, nested.options); + } + const typeInterfaceName = getTypeInterfaceName(nested); + formatter.writeLine(`${nested.name}: SubtypeConstructor<typeof grpc.Client, ${typeInterfaceName}Client> & { service: ${typeInterfaceName}Definition }`); + } + else if (nested instanceof Protobuf.Enum) { + formatter.writeLine(`${nested.name}: EnumTypeDefinition`); + } + else if (nested instanceof Protobuf.Type) { + formatter.writeLine(`${nested.name}: MessageTypeDefinition`); + } + else if (isNamespaceBase(nested)) { + generateLoadedDefinitionTypes(formatter, nested, options); + } +} +function generateLoadedDefinitionTypes(formatter, namespace, options) { + formatter.writeLine(`${namespace.name}: {`); + formatter.indent(); + for (const nested of namespace.nestedArray.sort(compareName)) { + generateSingleLoadedDefinitionType(formatter, nested, options); + } + formatter.unindent(); + formatter.writeLine('}'); +} +function generateRootFile(formatter, root, options) { + if (!options.grpcLib) { + return; + } + formatter.writeLine(`import type * as grpc from '${options.grpcLib}';`); + generateDefinitionImports(formatter, root, options); + formatter.writeLine(''); + generateServiceImports(formatter, root, options); + formatter.writeLine(''); + formatter.writeLine('type SubtypeConstructor<Constructor extends new (...args: any) => any, Subtype> = {'); + formatter.writeLine(' new(...args: ConstructorParameters<Constructor>): Subtype;'); + formatter.writeLine('};'); + formatter.writeLine(''); + formatter.writeLine('export interface ProtoGrpcType {'); + formatter.indent(); + for (const nested of root.nestedArray) { + generateSingleLoadedDefinitionType(formatter, nested, options); + } + formatter.unindent(); + formatter.writeLine('}'); + formatter.writeLine(''); +} +async function writeFile(filename, contents) { + await fs.promises.mkdir(path.dirname(filename), { recursive: true }); + return fs.promises.writeFile(filename, contents); +} +function generateFilesForNamespace(namespace, options) { + const filePromises = []; + for (const nested of namespace.nestedArray) { + const fileFormatter = new TextFormatter(); + if (nested instanceof Protobuf.Type) { + generateMessageInterfaces(fileFormatter, nested, options); + if (options.verbose) { + console.log(`Writing ${options.outDir}/${getPath(nested, options)} from file ${nested.filename}`); + } + filePromises.push(writeFile(`${options.outDir}/${getPath(nested, options)}`, fileFormatter.getFullText())); + } + else if (nested instanceof Protobuf.Enum) { + generateEnumInterface(fileFormatter, nested, options); + if (options.verbose) { + console.log(`Writing ${options.outDir}/${getPath(nested, options)} from file ${nested.filename}`); + } + filePromises.push(writeFile(`${options.outDir}/${getPath(nested, options)}`, fileFormatter.getFullText())); + } + else if (nested instanceof Protobuf.Service) { + generateServiceInterfaces(fileFormatter, nested, options); + if (options.verbose) { + console.log(`Writing ${options.outDir}/${getPath(nested, options)} from file ${nested.filename}`); + } + filePromises.push(writeFile(`${options.outDir}/${getPath(nested, options)}`, fileFormatter.getFullText())); + } + else if (isNamespaceBase(nested)) { + filePromises.push(...generateFilesForNamespace(nested, options)); + } + } + return filePromises; +} +function writeFilesForRoot(root, masterFileName, options) { + const filePromises = []; + const masterFileFormatter = new TextFormatter(); + if (options.grpcLib) { + generateRootFile(masterFileFormatter, root, options); + if (options.verbose) { + console.log(`Writing ${options.outDir}/${masterFileName}`); + } + filePromises.push(writeFile(`${options.outDir}/${masterFileName}`, masterFileFormatter.getFullText())); + } + filePromises.push(...generateFilesForNamespace(root, options)); + return filePromises; +} +async function writeAllFiles(protoFiles, options) { + await fs.promises.mkdir(options.outDir, { recursive: true }); + const basenameMap = new Map(); + for (const filename of protoFiles) { + const basename = path.basename(filename).replace(/\.proto$/, options.targetFileExtension); + if (basenameMap.has(basename)) { + basenameMap.get(basename).push(filename); + } + else { + basenameMap.set(basename, [filename]); + } + } + for (const [basename, filenames] of basenameMap.entries()) { + const loadedRoot = await (0, util_1.loadProtosWithOptions)(filenames, options); + writeFilesForRoot(loadedRoot, basename, options); + } +} +async function runScript() { + const boolDefaultFalseOption = { + boolean: true, + default: false, + }; + const argv = await yargs + .parserConfiguration({ + 'parse-positional-numbers': false + }) + .option('keepCase', boolDefaultFalseOption) + .option('longs', { string: true, default: 'Long' }) + .option('enums', { string: true, default: 'number' }) + .option('bytes', { string: true, default: 'Buffer' }) + .option('defaults', boolDefaultFalseOption) + .option('arrays', boolDefaultFalseOption) + .option('objects', boolDefaultFalseOption) + .option('oneofs', boolDefaultFalseOption) + .option('json', boolDefaultFalseOption) + .boolean('verbose') + .option('includeComments', boolDefaultFalseOption) + .option('includeDirs', { + normalize: true, + array: true, + alias: 'I' + }) + .option('outDir', { + alias: 'O', + normalize: true, + }) + .option('grpcLib', { string: true }) + .option('inputTemplate', { string: true, default: `${templateStr}` }) + .option('outputTemplate', { string: true, default: `${templateStr}__Output` }) + .option('inputBranded', boolDefaultFalseOption) + .option('outputBranded', boolDefaultFalseOption) + .option('targetFileExtension', { string: true, default: '.ts' }) + .option('importFileExtension', { string: true, default: '' }) + .coerce('longs', value => { + switch (value) { + case 'String': return String; + case 'Number': return Number; + default: return undefined; + } + }).coerce('enums', value => { + if (value === 'String') { + return String; + } + else { + return undefined; + } + }).coerce('bytes', value => { + switch (value) { + case 'Array': return Array; + case 'String': return String; + default: return undefined; + } + }) + .alias({ + verbose: 'v' + }).describe({ + keepCase: 'Preserve the case of field names', + longs: 'The type that should be used to output 64 bit integer values. Can be String, Number', + enums: 'The type that should be used to output enum fields. Can be String', + bytes: 'The type that should be used to output bytes fields. Can be String, Array', + defaults: 'Output default values for omitted fields', + arrays: 'Output default values for omitted repeated fields even if --defaults is not set', + objects: 'Output default values for omitted message fields even if --defaults is not set', + oneofs: 'Output virtual oneof fields set to the present field\'s name', + json: 'Represent Infinity and NaN as strings in float fields. Also decode google.protobuf.Any automatically', + includeComments: 'Generate doc comments from comments in the original files', + includeDirs: 'Directories to search for included files', + outDir: 'Directory in which to output files', + grpcLib: 'The gRPC implementation library that these types will be used with. If not provided, some types will not be generated', + inputTemplate: 'Template for mapping input or "permissive" type names', + outputTemplate: 'Template for mapping output or "restricted" type names', + inputBranded: 'Output property for branded type for "permissive" types with fullName of the Message as its value', + outputBranded: 'Output property for branded type for "restricted" types with fullName of the Message as its value', + targetFileExtension: 'File extension for generated files.', + importFileExtension: 'File extension for import specifiers in generated code.' + }).demandOption(['outDir']) + .demand(1) + .usage('$0 [options] filenames...') + .epilogue('WARNING: This tool is in alpha. The CLI and generated code are subject to change') + .argv; + if (argv.verbose) { + console.log('Parsed arguments:', argv); + } + (0, util_1.addCommonProtos)(); + writeAllFiles(argv._, Object.assign(Object.assign({}, argv), { alternateCommentMode: true })).then(() => { + if (argv.verbose) { + console.log('Success'); + } + }, (error) => { + console.error(error); + process.exit(1); + }); +} +if (require.main === module) { + runScript(); +} +//# sourceMappingURL=proto-loader-gen-types.js.map
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js.map b/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js.map new file mode 100644 index 0000000..229cd48 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/bin/proto-loader-gen-types.js.map @@ -0,0 +1 @@ +{"version":3,"file":"proto-loader-gen-types.js","sourceRoot":"","sources":["../../bin/proto-loader-gen-types.ts"],"names":[],"mappings":";;AACA;;;;;;;;;;;;;;;;GAgBG;;AAEH,yBAAyB;AACzB,6BAA6B;AAE7B,uCAAuC;AACvC,+BAA+B;AAE/B,8CAA+C;AAC/C,sCAAqE;AAErE,MAAM,WAAW,GAAG,IAAI,CAAC;AACzB,MAAM,YAAY,GAAG,CAAC,EAAC,cAAc,EAAE,aAAa,EAAmB,EAAE,EAAE;IACzE,IAAI,cAAc,KAAK,aAAa,EAAE;QACpC,MAAM,IAAI,KAAK,CAAC,8CAA8C,CAAC,CAAA;KAChE;IACD,OAAO;QACL,UAAU,EAAE,CAAC,CAAS,EAAE,EAAE,CAAC,cAAc,CAAC,OAAO,CAAC,WA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,IAAI,CAAC,CAAC;KACxC;IACD,IAAA,sBAAe,GAAE,CAAC;IAClB,aAAa,CAAC,IAAI,CAAC,CAAa,kCAAM,IAAI,KAAE,oBAAoB,EAAE,IAAI,IAAE,CAAC,IAAI,CAAC,GAAG,EAAE;QACjF,IAAI,IAAI,CAAC,OAAO,EAAE;YAChB,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;SACxB;IACH,CAAC,EAAE,CAAC,KAAK,EAAE,EAAE;QACX,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAA;QACpB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;AACL,CAAC;AAED,IAAI,OAAO,CAAC,IAAI,KAAK,MAAM,EAAE;IAC3B,SAAS,EAAE,CAAC;CACb"}
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/index.d.ts b/frontend-old/node_modules/@grpc/proto-loader/build/src/index.d.ts new file mode 100644 index 0000000..ff575c0 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/index.d.ts @@ -0,0 +1,160 @@ +/** + * @license + * Copyright 2018 gRPC authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +/// <reference types="node" /> +import * as Protobuf from 'protobufjs'; +import * as descriptor from 'protobufjs/ext/descriptor'; +import { Options } from './util'; +import Long = require('long'); +export { Options, Long }; +/** + * This type exists for use with code generated by the proto-loader-gen-types + * tool. This type should be used with another interface, e.g. + * MessageType & AnyExtension for an object that is converted to or from a + * google.protobuf.Any message. + * For example, when processing an Any message: + * + * ```ts + * if (isAnyExtension(message)) { + * switch (message['@type']) { + * case TYPE1_URL: + * handleType1(message as AnyExtension & Type1); + * break; + * case TYPE2_URL: + * handleType2(message as AnyExtension & Type2); + * break; + * // ... + * } + * } + * ``` + */ +export interface AnyExtension { + /** + * The fully qualified name of the message type that this object represents, + * possibly including a URL prefix. + */ + '@type': string; +} +export declare function isAnyExtension(obj: object): obj is AnyExtension; +declare module 'protobufjs' { + interface Type { + toDescriptor(protoVersion: string): Protobuf.Message<descriptor.IDescriptorProto> & descriptor.IDescriptorProto; + } + interface RootConstructor { + new (options?: Options): Root; + fromDescriptor(descriptorSet: descriptor.IFileDescriptorSet | Protobuf.Reader | Uint8Array): Root; + fromJSON(json: Protobuf.INamespace, root?: Root): Root; + } + interface Root { + toDescriptor(protoVersion: string): Protobuf.Message<descriptor.IFileDescriptorSet> & descriptor.IFileDescriptorSet; + } + interface Enum { + toDescriptor(protoVersion: string): Protobuf.Message<descriptor.IEnumDescriptorProto> & descriptor.IEnumDescriptorProto; + } +} +export interface Serialize<T> { + (value: T): Buffer; +} +export interface Deserialize<T> { + (bytes: Buffer): T; +} +export interface ProtobufTypeDefinition { + format: string; + type: object; + fileDescriptorProtos: Buffer[]; +} +export interface MessageTypeDefinition extends ProtobufTypeDefinition { + format: 'Protocol Buffer 3 DescriptorProto'; +} +export interface EnumTypeDefinition extends ProtobufTypeDefinition { + format: 'Protocol Buffer 3 EnumDescriptorProto'; +} +export declare enum IdempotencyLevel { + IDEMPOTENCY_UNKNOWN = "IDEMPOTENCY_UNKNOWN", + NO_SIDE_EFFECTS = "NO_SIDE_EFFECTS", + IDEMPOTENT = "IDEMPOTENT" +} +export interface NamePart { + name_part: string; + is_extension: boolean; +} +export interface UninterpretedOption { + name?: NamePart[]; + identifier_value?: string; + positive_int_value?: number; + negative_int_value?: number; + double_value?: number; + string_value?: string; + aggregate_value?: string; +} +export interface MethodOptions { + deprecated: boolean; + idempotency_level: IdempotencyLevel; + uninterpreted_option: UninterpretedOption[]; + [k: string]: unknown; +} +export interface MethodDefinition<RequestType, ResponseType, OutputRequestType = RequestType, OutputResponseType = ResponseType> { + path: string; + requestStream: boolean; + responseStream: boolean; + requestSerialize: Serialize<RequestType>; + responseSerialize: Serialize<ResponseType>; + requestDeserialize: Deserialize<OutputRequestType>; + responseDeserialize: Deserialize<OutputResponseType>; + originalName?: string; + requestType: MessageTypeDefinition; + responseType: MessageTypeDefinition; + options: MethodOptions; +} +export interface ServiceDefinition { + [index: string]: MethodDefinition<object, object>; +} +export declare type AnyDefinition = ServiceDefinition | MessageTypeDefinition | EnumTypeDefinition; +export interface PackageDefinition { + [index: string]: AnyDefinition; +} +/** + * Load a .proto file with the specified options. + * @param filename One or multiple file paths to load. Can be an absolute path + * or relative to an include path. + * @param options.keepCase Preserve field names. The default is to change them + * to camel case. + * @param options.longs The type that should be used to represent `long` values. + * Valid options are `Number` and `String`. Defaults to a `Long` object type + * from a library. + * @param options.enums The type that should be used to represent `enum` values. + * The only valid option is `String`. Defaults to the numeric value. + * @param options.bytes The type that should be used to represent `bytes` + * values. Valid options are `Array` and `String`. The default is to use + * `Buffer`. + * @param options.defaults Set default values on output objects. Defaults to + * `false`. + * @param options.arrays Set empty arrays for missing array values even if + * `defaults` is `false`. Defaults to `false`. + * @param options.objects Set empty objects for missing object values even if + * `defaults` is `false`. Defaults to `false`. + * @param options.oneofs Set virtual oneof properties to the present field's + * name + * @param options.json Represent Infinity and NaN as strings in float fields, + * and automatically decode google.protobuf.Any values. + * @param options.includeDirs Paths to search for imported `.proto` files. + */ +export declare function load(filename: string | string[], options?: Options): Promise<PackageDefinition>; +export declare function loadSync(filename: string | string[], options?: Options): PackageDefinition; +export declare function fromJSON(json: Protobuf.INamespace, options?: Options): PackageDefinition; +export declare function loadFileDescriptorSetFromBuffer(descriptorSet: Buffer, options?: Options): PackageDefinition; +export declare function loadFileDescriptorSetFromObject(descriptorSet: Parameters<typeof descriptor.FileDescriptorSet.fromObject>[0], options?: Options): PackageDefinition; diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/index.js b/frontend-old/node_modules/@grpc/proto-loader/build/src/index.js new file mode 100644 index 0000000..1d86395 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/index.js @@ -0,0 +1,244 @@ +"use strict"; +/** + * @license + * Copyright 2018 gRPC authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.loadFileDescriptorSetFromObject = exports.loadFileDescriptorSetFromBuffer = exports.fromJSON = exports.loadSync = exports.load = exports.IdempotencyLevel = exports.isAnyExtension = exports.Long = void 0; +const camelCase = require("lodash.camelcase"); +const Protobuf = require("protobufjs"); +const descriptor = require("protobufjs/ext/descriptor"); +const util_1 = require("./util"); +const Long = require("long"); +exports.Long = Long; +function isAnyExtension(obj) { + return ('@type' in obj) && (typeof obj['@type'] === 'string'); +} +exports.isAnyExtension = isAnyExtension; +var IdempotencyLevel; +(function (IdempotencyLevel) { + IdempotencyLevel["IDEMPOTENCY_UNKNOWN"] = "IDEMPOTENCY_UNKNOWN"; + IdempotencyLevel["NO_SIDE_EFFECTS"] = "NO_SIDE_EFFECTS"; + IdempotencyLevel["IDEMPOTENT"] = "IDEMPOTENT"; +})(IdempotencyLevel = exports.IdempotencyLevel || (exports.IdempotencyLevel = {})); +const descriptorOptions = { + longs: String, + enums: String, + bytes: String, + defaults: true, + oneofs: true, + json: true, +}; +function joinName(baseName, name) { + if (baseName === '') { + return name; + } + else { + return baseName + '.' + name; + } +} +function isHandledReflectionObject(obj) { + return (obj instanceof Protobuf.Service || + obj instanceof Protobuf.Type || + obj instanceof Protobuf.Enum); +} +function isNamespaceBase(obj) { + return obj instanceof Protobuf.Namespace || obj instanceof Protobuf.Root; +} +function getAllHandledReflectionObjects(obj, parentName) { + const objName = joinName(parentName, obj.name); + if (isHandledReflectionObject(obj)) { + return [[objName, obj]]; + } + else { + if (isNamespaceBase(obj) && typeof obj.nested !== 'undefined') { + return Object.keys(obj.nested) + .map(name => { + return getAllHandledReflectionObjects(obj.nested[name], objName); + }) + .reduce((accumulator, currentValue) => accumulator.concat(currentValue), []); + } + } + return []; +} +function createDeserializer(cls, options) { + return function deserialize(argBuf) { + return cls.toObject(cls.decode(argBuf), options); + }; +} +function createSerializer(cls) { + return function serialize(arg) { + if (Array.isArray(arg)) { + throw new Error(`Failed to serialize message: expected object with ${cls.name} structure, got array instead`); + } + const message = cls.fromObject(arg); + return cls.encode(message).finish(); + }; +} +function mapMethodOptions(options) { + return (options || []).reduce((obj, item) => { + for (const [key, value] of Object.entries(item)) { + switch (key) { + case 'uninterpreted_option': + obj.uninterpreted_option.push(item.uninterpreted_option); + break; + default: + obj[key] = value; + } + } + return obj; + }, { + deprecated: false, + idempotency_level: IdempotencyLevel.IDEMPOTENCY_UNKNOWN, + uninterpreted_option: [], + }); +} +function createMethodDefinition(method, serviceName, options, fileDescriptors) { + /* This is only ever called after the corresponding root.resolveAll(), so we + * can assume that the resolved request and response types are non-null */ + const requestType = method.resolvedRequestType; + const responseType = method.resolvedResponseType; + return { + path: '/' + serviceName + '/' + method.name, + requestStream: !!method.requestStream, + responseStream: !!method.responseStream, + requestSerialize: createSerializer(requestType), + requestDeserialize: createDeserializer(requestType, options), + responseSerialize: createSerializer(responseType), + responseDeserialize: createDeserializer(responseType, options), + // TODO(murgatroid99): Find a better way to handle this + originalName: camelCase(method.name), + requestType: createMessageDefinition(requestType, fileDescriptors), + responseType: createMessageDefinition(responseType, fileDescriptors), + options: mapMethodOptions(method.parsedOptions), + }; +} +function createServiceDefinition(service, name, options, fileDescriptors) { + const def = {}; + for (const method of service.methodsArray) { + def[method.name] = createMethodDefinition(method, name, options, fileDescriptors); + } + return def; +} +function createMessageDefinition(message, fileDescriptors) { + const messageDescriptor = message.toDescriptor('proto3'); + return { + format: 'Protocol Buffer 3 DescriptorProto', + type: messageDescriptor.$type.toObject(messageDescriptor, descriptorOptions), + fileDescriptorProtos: fileDescriptors, + }; +} +function createEnumDefinition(enumType, fileDescriptors) { + const enumDescriptor = enumType.toDescriptor('proto3'); + return { + format: 'Protocol Buffer 3 EnumDescriptorProto', + type: enumDescriptor.$type.toObject(enumDescriptor, descriptorOptions), + fileDescriptorProtos: fileDescriptors, + }; +} +/** + * function createDefinition(obj: Protobuf.Service, name: string, options: + * Options): ServiceDefinition; function createDefinition(obj: Protobuf.Type, + * name: string, options: Options): MessageTypeDefinition; function + * createDefinition(obj: Protobuf.Enum, name: string, options: Options): + * EnumTypeDefinition; + */ +function createDefinition(obj, name, options, fileDescriptors) { + if (obj instanceof Protobuf.Service) { + return createServiceDefinition(obj, name, options, fileDescriptors); + } + else if (obj instanceof Protobuf.Type) { + return createMessageDefinition(obj, fileDescriptors); + } + else if (obj instanceof Protobuf.Enum) { + return createEnumDefinition(obj, fileDescriptors); + } + else { + throw new Error('Type mismatch in reflection object handling'); + } +} +function createPackageDefinition(root, options) { + const def = {}; + root.resolveAll(); + const descriptorList = root.toDescriptor('proto3').file; + const bufferList = descriptorList.map(value => Buffer.from(descriptor.FileDescriptorProto.encode(value).finish())); + for (const [name, obj] of getAllHandledReflectionObjects(root, '')) { + def[name] = createDefinition(obj, name, options, bufferList); + } + return def; +} +function createPackageDefinitionFromDescriptorSet(decodedDescriptorSet, options) { + options = options || {}; + const root = Protobuf.Root.fromDescriptor(decodedDescriptorSet); + root.resolveAll(); + return createPackageDefinition(root, options); +} +/** + * Load a .proto file with the specified options. + * @param filename One or multiple file paths to load. Can be an absolute path + * or relative to an include path. + * @param options.keepCase Preserve field names. The default is to change them + * to camel case. + * @param options.longs The type that should be used to represent `long` values. + * Valid options are `Number` and `String`. Defaults to a `Long` object type + * from a library. + * @param options.enums The type that should be used to represent `enum` values. + * The only valid option is `String`. Defaults to the numeric value. + * @param options.bytes The type that should be used to represent `bytes` + * values. Valid options are `Array` and `String`. The default is to use + * `Buffer`. + * @param options.defaults Set default values on output objects. Defaults to + * `false`. + * @param options.arrays Set empty arrays for missing array values even if + * `defaults` is `false`. Defaults to `false`. + * @param options.objects Set empty objects for missing object values even if + * `defaults` is `false`. Defaults to `false`. + * @param options.oneofs Set virtual oneof properties to the present field's + * name + * @param options.json Represent Infinity and NaN as strings in float fields, + * and automatically decode google.protobuf.Any values. + * @param options.includeDirs Paths to search for imported `.proto` files. + */ +function load(filename, options) { + return (0, util_1.loadProtosWithOptions)(filename, options).then(loadedRoot => { + return createPackageDefinition(loadedRoot, options); + }); +} +exports.load = load; +function loadSync(filename, options) { + const loadedRoot = (0, util_1.loadProtosWithOptionsSync)(filename, options); + return createPackageDefinition(loadedRoot, options); +} +exports.loadSync = loadSync; +function fromJSON(json, options) { + options = options || {}; + const loadedRoot = Protobuf.Root.fromJSON(json); + loadedRoot.resolveAll(); + return createPackageDefinition(loadedRoot, options); +} +exports.fromJSON = fromJSON; +function loadFileDescriptorSetFromBuffer(descriptorSet, options) { + const decodedDescriptorSet = descriptor.FileDescriptorSet.decode(descriptorSet); + return createPackageDefinitionFromDescriptorSet(decodedDescriptorSet, options); +} +exports.loadFileDescriptorSetFromBuffer = loadFileDescriptorSetFromBuffer; +function loadFileDescriptorSetFromObject(descriptorSet, options) { + const decodedDescriptorSet = descriptor.FileDescriptorSet.fromObject(descriptorSet); + return createPackageDefinitionFromDescriptorSet(decodedDescriptorSet, options); +} +exports.loadFileDescriptorSetFromObject = loadFileDescriptorSetFromObject; +(0, util_1.addCommonProtos)(); +//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/index.js.map b/frontend-old/node_modules/@grpc/proto-loader/build/src/index.js.map new file mode 100644 index 0000000..8ba05f1 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/index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aAAa,CACU,CAAC;IAE1B,OAAO,wCAAwC,CAC7C,oBAAoB,EACpB,OAAO,CACR,CAAC;AACJ,CAAC;AAZD,0EAYC;AAED,IAAA,sBAAe,GAAE,CAAC"}
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/util.d.ts b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.d.ts new file mode 100644 index 0000000..d0b13d9 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.d.ts @@ -0,0 +1,27 @@ +/** + * @license + * Copyright 2018 gRPC authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +import * as Protobuf from 'protobufjs'; +export declare type Options = Protobuf.IParseOptions & Protobuf.IConversionOptions & { + includeDirs?: string[]; +}; +export declare function loadProtosWithOptions(filename: string | string[], options?: Options): Promise<Protobuf.Root>; +export declare function loadProtosWithOptionsSync(filename: string | string[], options?: Options): Protobuf.Root; +/** + * Load Google's well-known proto files that aren't exposed by Protobuf.js. + */ +export declare function addCommonProtos(): void; diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js new file mode 100644 index 0000000..7ade36b --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js @@ -0,0 +1,89 @@ +"use strict"; +/** + * @license + * Copyright 2018 gRPC authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.addCommonProtos = exports.loadProtosWithOptionsSync = exports.loadProtosWithOptions = void 0; +const fs = require("fs"); +const path = require("path"); +const Protobuf = require("protobufjs"); +function addIncludePathResolver(root, includePaths) { + const originalResolvePath = root.resolvePath; + root.resolvePath = (origin, target) => { + if (path.isAbsolute(target)) { + return target; + } + for (const directory of includePaths) { + const fullPath = path.join(directory, target); + try { + fs.accessSync(fullPath, fs.constants.R_OK); + return fullPath; + } + catch (err) { + continue; + } + } + process.emitWarning(`${target} not found in any of the include paths ${includePaths}`); + return originalResolvePath(origin, target); + }; +} +async function loadProtosWithOptions(filename, options) { + const root = new Protobuf.Root(); + options = options || {}; + if (!!options.includeDirs) { + if (!Array.isArray(options.includeDirs)) { + return Promise.reject(new Error('The includeDirs option must be an array')); + } + addIncludePathResolver(root, options.includeDirs); + } + const loadedRoot = await root.load(filename, options); + loadedRoot.resolveAll(); + return loadedRoot; +} +exports.loadProtosWithOptions = loadProtosWithOptions; +function loadProtosWithOptionsSync(filename, options) { + const root = new Protobuf.Root(); + options = options || {}; + if (!!options.includeDirs) { + if (!Array.isArray(options.includeDirs)) { + throw new Error('The includeDirs option must be an array'); + } + addIncludePathResolver(root, options.includeDirs); + } + const loadedRoot = root.loadSync(filename, options); + loadedRoot.resolveAll(); + return loadedRoot; +} +exports.loadProtosWithOptionsSync = loadProtosWithOptionsSync; +/** + * Load Google's well-known proto files that aren't exposed by Protobuf.js. + */ +function addCommonProtos() { + // Protobuf.js exposes: any, duration, empty, field_mask, struct, timestamp, + // and wrappers. compiler/plugin is excluded in Protobuf.js and here. + // Using constant strings for compatibility with tools like Webpack + const apiDescriptor = require('protobufjs/google/protobuf/api.json'); + const descriptorDescriptor = require('protobufjs/google/protobuf/descriptor.json'); + const sourceContextDescriptor = require('protobufjs/google/protobuf/source_context.json'); + const typeDescriptor = require('protobufjs/google/protobuf/type.json'); + Protobuf.common('api', apiDescriptor.nested.google.nested.protobuf.nested); + Protobuf.common('descriptor', descriptorDescriptor.nested.google.nested.protobuf.nested); + Protobuf.common('source_context', sourceContextDescriptor.nested.google.nested.protobuf.nested); + Protobuf.common('type', typeDescriptor.nested.google.nested.protobuf.nested); +} +exports.addCommonProtos = addCommonProtos; +//# sourceMappingURL=util.js.map
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js.map b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js.map new file mode 100644 index 0000000..bb517f7 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/build/src/util.js.map @@ -0,0 +1 @@ +{"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;AAEH,yBAAyB;AACzB,6BAA6B;AAC7B,uCAAuC;AAEvC,SAAS,sBAAsB,CAAC,IAAmB,EAAE,YAAsB;IACzE,MAAM,mBAAmB,GAAG,IAAI,CAAC,WAAW,CAAC;IAC7C,IAAI,CAAC,WAAW,GAAG,CAAC,MAAc,EAAE,MAAc,EAAE,EAAE;QACpD,IAAI,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE;YAC3B,OAAO,MAAM,CAAC;SACf;QACD,KAAK,MAAM,SAAS,IAAI,YAAY,EAAE;YACpC,MAAM,QAAQ,GAAW,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;YACtD,IAAI;gBACF,EAAE,CAAC,UAAU,CAAC,QAAQ,EAAE,EAAE,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;gBAC3C,OAAO,QAAQ,CAAC;aACjB;YAAC,OAAO,GAAG,EAAE;gBACZ,SAAS;aACV;SACF;QACD,OAAO,CAAC,WAAW,CAAC,GAAG,MAAM,0CAA0C,YAAY,EAAE,CAAC,CAAC;QACvF,OAAO,mBAAmB,CAAC,MAAM,E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;;GAEG;AACH,SAAgB,eAAe;IAC7B,4EAA4E;IAC5E,qEAAqE;IAErE,mEAAmE;IACnE,MAAM,aAAa,GAAG,OAAO,CAAC,qCAAqC,CAAC,CAAC;IACrE,MAAM,oBAAoB,GAAG,OAAO,CAAC,4CAA4C,CAAC,CAAC;IACnF,MAAM,uBAAuB,GAAG,OAAO,CAAC,gDAAgD,CAAC,CAAC;IAC1F,MAAM,cAAc,GAAG,OAAO,CAAC,sCAAsC,CAAC,CAAC;IAEvE,QAAQ,CAAC,MAAM,CACb,KAAK,EACL,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CACnD,CAAC;IACF,QAAQ,CAAC,MAAM,CACb,YAAY,EACZ,oBAAoB,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAC1D,CAAC;IACF,QAAQ,CAAC,MAAM,CACb,gBAAgB,EAChB,uBAAuB,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAC7D,CAAC;IACF,QAAQ,CAAC,MAAM,CACb,MAAM,EACN,cAAc,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CACpD,CAAC;AACJ,CAAC;AA1BD,0CA0BC"}
\ No newline at end of file diff --git a/frontend-old/node_modules/@grpc/proto-loader/package.json b/frontend-old/node_modules/@grpc/proto-loader/package.json new file mode 100644 index 0000000..d9da2f7 --- /dev/null +++ b/frontend-old/node_modules/@grpc/proto-loader/package.json @@ -0,0 +1,69 @@ +{ + "name": "@grpc/proto-loader", + "version": "0.7.15", + "author": "Google Inc.", + "contributors": [ + { + "name": "Michael Lumish", + "email": "mlumish@google.com" + } + ], + "description": "gRPC utility library for loading .proto files", + "homepage": "https://grpc.io/", + "main": "build/src/index.js", + "typings": "build/src/index.d.ts", + "scripts": { + "build": "npm run compile", + "clean": "rimraf ./build", + "compile": "tsc -p .", + "format": "clang-format -i -style=\"{Language: JavaScript, BasedOnStyle: Google, ColumnLimit: 80}\" src/*.ts test/*.ts", + "lint": "tslint -c node_modules/google-ts-style/tslint.json -p . -t codeFrame --type-check", + "prepare": "npm run compile", + "test": "gulp test", + "check": "gts check", + "fix": "gts fix", + "pretest": "npm run compile", + "posttest": "npm run check", + "generate-golden": "node ./build/bin/proto-loader-gen-types.js --keepCase --longs=String --enums=String --defaults --oneofs --json --includeComments --inputTemplate=I%s --outputTemplate=O%s -I deps/gapic-showcase/schema/ deps/googleapis/ -O ./golden-generated --grpcLib @grpc/grpc-js google/showcase/v1beta1/echo.proto", + "validate-golden": "rm -rf ./golden-generated-old && mv ./golden-generated/ ./golden-generated-old && npm run generate-golden && diff -rb ./golden-generated ./golden-generated-old" + }, + "repository": { + "type": "git", + "url": "https://github.com/grpc/grpc-node.git" + }, + "license": "Apache-2.0", + "bugs": { + "url": "https://github.com/grpc/grpc-node/issues" + }, + "files": [ + "LICENSE", + "build/src/*.d.ts", + "build/src/*.{js,js.map}", + "build/bin/*.{js,js.map}" + ], + "bin": { + "proto-loader-gen-types": "./build/bin/proto-loader-gen-types.js" + }, + "dependencies": { + "lodash.camelcase": "^4.3.0", + "long": "^5.0.0", + "protobufjs": "^7.2.5", + "yargs": "^17.7.2" + }, + "devDependencies": { + "@types/lodash.camelcase": "^4.3.4", + "@types/mkdirp": "^1.0.1", + "@types/mocha": "^5.2.7", + "@types/node": "^10.17.26", + "@types/yargs": "^17.0.24", + "clang-format": "^1.2.2", + "google-proto-files": "^3.0.2", + "gts": "^3.1.0", + "rimraf": "^3.0.2", + "ts-node": "^10.9.2", + "typescript": "~4.7.4" + }, + "engines": { + "node": ">=6" + } +} |
