"use strict";
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
//   protoc-gen-ts_proto  v2.11.8
//   protoc               v4.25.9
// source: grpc/reflection/v1/reflection.proto
Object.defineProperty(exports, "__esModule", { value: true });
exports.protoMetadata = exports.ServerReflectionDefinition = exports.ErrorResponse = exports.ServiceResponse = exports.ListServiceResponse = exports.ExtensionNumberResponse = exports.FileDescriptorResponse = exports.ServerReflectionResponse = exports.ExtensionRequest = exports.ServerReflectionRequest = exports.protobufPackage = void 0;
/* eslint-disable */
const wire_1 = require("@bufbuild/protobuf/wire");
exports.protobufPackage = "grpc.reflection.v1";
function createBaseServerReflectionRequest() {
    return {};
}
exports.ServerReflectionRequest = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.host !== undefined && message.host !== "") {
            writer.uint32(10).string(message.host);
        }
        if (message.file_by_filename !== undefined) {
            writer.uint32(26).string(message.file_by_filename);
        }
        if (message.file_containing_symbol !== undefined) {
            writer.uint32(34).string(message.file_containing_symbol);
        }
        if (message.file_containing_extension !== undefined) {
            exports.ExtensionRequest.encode(message.file_containing_extension, writer.uint32(42).fork()).join();
        }
        if (message.all_extension_numbers_of_type !== undefined) {
            writer.uint32(50).string(message.all_extension_numbers_of_type);
        }
        if (message.list_services !== undefined) {
            writer.uint32(58).string(message.list_services);
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseServerReflectionRequest();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    message.host = reader.string();
                    continue;
                }
                case 3: {
                    if (tag !== 26) {
                        break;
                    }
                    message.file_by_filename = reader.string();
                    continue;
                }
                case 4: {
                    if (tag !== 34) {
                        break;
                    }
                    message.file_containing_symbol = reader.string();
                    continue;
                }
                case 5: {
                    if (tag !== 42) {
                        break;
                    }
                    message.file_containing_extension = exports.ExtensionRequest.decode(reader, reader.uint32());
                    continue;
                }
                case 6: {
                    if (tag !== 50) {
                        break;
                    }
                    message.all_extension_numbers_of_type = reader.string();
                    continue;
                }
                case 7: {
                    if (tag !== 58) {
                        break;
                    }
                    message.list_services = reader.string();
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            host: isSet(object.host) ? globalThis.String(object.host) : undefined,
            file_by_filename: isSet(object.fileByFilename)
                ? globalThis.String(object.fileByFilename)
                : isSet(object.file_by_filename)
                    ? globalThis.String(object.file_by_filename)
                    : undefined,
            file_containing_symbol: isSet(object.fileContainingSymbol)
                ? globalThis.String(object.fileContainingSymbol)
                : isSet(object.file_containing_symbol)
                    ? globalThis.String(object.file_containing_symbol)
                    : undefined,
            file_containing_extension: isSet(object.fileContainingExtension)
                ? exports.ExtensionRequest.fromJSON(object.fileContainingExtension)
                : isSet(object.file_containing_extension)
                    ? exports.ExtensionRequest.fromJSON(object.file_containing_extension)
                    : undefined,
            all_extension_numbers_of_type: isSet(object.allExtensionNumbersOfType)
                ? globalThis.String(object.allExtensionNumbersOfType)
                : isSet(object.all_extension_numbers_of_type)
                    ? globalThis.String(object.all_extension_numbers_of_type)
                    : undefined,
            list_services: isSet(object.listServices)
                ? globalThis.String(object.listServices)
                : isSet(object.list_services)
                    ? globalThis.String(object.list_services)
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.host !== undefined && message.host !== "") {
            obj.host = message.host;
        }
        if (message.file_by_filename !== undefined) {
            obj.fileByFilename = message.file_by_filename;
        }
        if (message.file_containing_symbol !== undefined) {
            obj.fileContainingSymbol = message.file_containing_symbol;
        }
        if (message.file_containing_extension !== undefined) {
            obj.fileContainingExtension = exports.ExtensionRequest.toJSON(message.file_containing_extension);
        }
        if (message.all_extension_numbers_of_type !== undefined) {
            obj.allExtensionNumbersOfType = message.all_extension_numbers_of_type;
        }
        if (message.list_services !== undefined) {
            obj.listServices = message.list_services;
        }
        return obj;
    },
    create(base) {
        return exports.ServerReflectionRequest.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseServerReflectionRequest();
        message.host = object.host ?? undefined;
        message.file_by_filename = object.file_by_filename ?? undefined;
        message.file_containing_symbol = object.file_containing_symbol ?? undefined;
        message.file_containing_extension =
            (object.file_containing_extension !== undefined && object.file_containing_extension !== null)
                ? exports.ExtensionRequest.fromPartial(object.file_containing_extension)
                : undefined;
        message.all_extension_numbers_of_type = object.all_extension_numbers_of_type ?? undefined;
        message.list_services = object.list_services ?? undefined;
        return message;
    },
};
function createBaseExtensionRequest() {
    return {};
}
exports.ExtensionRequest = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.containing_type !== undefined && message.containing_type !== "") {
            writer.uint32(10).string(message.containing_type);
        }
        if (message.extension_number !== undefined && message.extension_number !== 0) {
            writer.uint32(16).int32(message.extension_number);
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseExtensionRequest();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    message.containing_type = reader.string();
                    continue;
                }
                case 2: {
                    if (tag !== 16) {
                        break;
                    }
                    message.extension_number = reader.int32();
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            containing_type: isSet(object.containingType)
                ? globalThis.String(object.containingType)
                : isSet(object.containing_type)
                    ? globalThis.String(object.containing_type)
                    : undefined,
            extension_number: isSet(object.extensionNumber)
                ? globalThis.Number(object.extensionNumber)
                : isSet(object.extension_number)
                    ? globalThis.Number(object.extension_number)
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.containing_type !== undefined && message.containing_type !== "") {
            obj.containingType = message.containing_type;
        }
        if (message.extension_number !== undefined && message.extension_number !== 0) {
            obj.extensionNumber = Math.round(message.extension_number);
        }
        return obj;
    },
    create(base) {
        return exports.ExtensionRequest.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseExtensionRequest();
        message.containing_type = object.containing_type ?? undefined;
        message.extension_number = object.extension_number ?? undefined;
        return message;
    },
};
function createBaseServerReflectionResponse() {
    return {};
}
exports.ServerReflectionResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.valid_host !== undefined && message.valid_host !== "") {
            writer.uint32(10).string(message.valid_host);
        }
        if (message.original_request !== undefined) {
            exports.ServerReflectionRequest.encode(message.original_request, writer.uint32(18).fork()).join();
        }
        if (message.file_descriptor_response !== undefined) {
            exports.FileDescriptorResponse.encode(message.file_descriptor_response, writer.uint32(34).fork()).join();
        }
        if (message.all_extension_numbers_response !== undefined) {
            exports.ExtensionNumberResponse.encode(message.all_extension_numbers_response, writer.uint32(42).fork()).join();
        }
        if (message.list_services_response !== undefined) {
            exports.ListServiceResponse.encode(message.list_services_response, writer.uint32(50).fork()).join();
        }
        if (message.error_response !== undefined) {
            exports.ErrorResponse.encode(message.error_response, writer.uint32(58).fork()).join();
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseServerReflectionResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    message.valid_host = reader.string();
                    continue;
                }
                case 2: {
                    if (tag !== 18) {
                        break;
                    }
                    message.original_request = exports.ServerReflectionRequest.decode(reader, reader.uint32());
                    continue;
                }
                case 4: {
                    if (tag !== 34) {
                        break;
                    }
                    message.file_descriptor_response = exports.FileDescriptorResponse.decode(reader, reader.uint32());
                    continue;
                }
                case 5: {
                    if (tag !== 42) {
                        break;
                    }
                    message.all_extension_numbers_response = exports.ExtensionNumberResponse.decode(reader, reader.uint32());
                    continue;
                }
                case 6: {
                    if (tag !== 50) {
                        break;
                    }
                    message.list_services_response = exports.ListServiceResponse.decode(reader, reader.uint32());
                    continue;
                }
                case 7: {
                    if (tag !== 58) {
                        break;
                    }
                    message.error_response = exports.ErrorResponse.decode(reader, reader.uint32());
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            valid_host: isSet(object.validHost)
                ? globalThis.String(object.validHost)
                : isSet(object.valid_host)
                    ? globalThis.String(object.valid_host)
                    : undefined,
            original_request: isSet(object.originalRequest)
                ? exports.ServerReflectionRequest.fromJSON(object.originalRequest)
                : isSet(object.original_request)
                    ? exports.ServerReflectionRequest.fromJSON(object.original_request)
                    : undefined,
            file_descriptor_response: isSet(object.fileDescriptorResponse)
                ? exports.FileDescriptorResponse.fromJSON(object.fileDescriptorResponse)
                : isSet(object.file_descriptor_response)
                    ? exports.FileDescriptorResponse.fromJSON(object.file_descriptor_response)
                    : undefined,
            all_extension_numbers_response: isSet(object.allExtensionNumbersResponse)
                ? exports.ExtensionNumberResponse.fromJSON(object.allExtensionNumbersResponse)
                : isSet(object.all_extension_numbers_response)
                    ? exports.ExtensionNumberResponse.fromJSON(object.all_extension_numbers_response)
                    : undefined,
            list_services_response: isSet(object.listServicesResponse)
                ? exports.ListServiceResponse.fromJSON(object.listServicesResponse)
                : isSet(object.list_services_response)
                    ? exports.ListServiceResponse.fromJSON(object.list_services_response)
                    : undefined,
            error_response: isSet(object.errorResponse)
                ? exports.ErrorResponse.fromJSON(object.errorResponse)
                : isSet(object.error_response)
                    ? exports.ErrorResponse.fromJSON(object.error_response)
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.valid_host !== undefined && message.valid_host !== "") {
            obj.validHost = message.valid_host;
        }
        if (message.original_request !== undefined) {
            obj.originalRequest = exports.ServerReflectionRequest.toJSON(message.original_request);
        }
        if (message.file_descriptor_response !== undefined) {
            obj.fileDescriptorResponse = exports.FileDescriptorResponse.toJSON(message.file_descriptor_response);
        }
        if (message.all_extension_numbers_response !== undefined) {
            obj.allExtensionNumbersResponse = exports.ExtensionNumberResponse.toJSON(message.all_extension_numbers_response);
        }
        if (message.list_services_response !== undefined) {
            obj.listServicesResponse = exports.ListServiceResponse.toJSON(message.list_services_response);
        }
        if (message.error_response !== undefined) {
            obj.errorResponse = exports.ErrorResponse.toJSON(message.error_response);
        }
        return obj;
    },
    create(base) {
        return exports.ServerReflectionResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseServerReflectionResponse();
        message.valid_host = object.valid_host ?? undefined;
        message.original_request = (object.original_request !== undefined && object.original_request !== null)
            ? exports.ServerReflectionRequest.fromPartial(object.original_request)
            : undefined;
        message.file_descriptor_response =
            (object.file_descriptor_response !== undefined && object.file_descriptor_response !== null)
                ? exports.FileDescriptorResponse.fromPartial(object.file_descriptor_response)
                : undefined;
        message.all_extension_numbers_response =
            (object.all_extension_numbers_response !== undefined && object.all_extension_numbers_response !== null)
                ? exports.ExtensionNumberResponse.fromPartial(object.all_extension_numbers_response)
                : undefined;
        message.list_services_response =
            (object.list_services_response !== undefined && object.list_services_response !== null)
                ? exports.ListServiceResponse.fromPartial(object.list_services_response)
                : undefined;
        message.error_response = (object.error_response !== undefined && object.error_response !== null)
            ? exports.ErrorResponse.fromPartial(object.error_response)
            : undefined;
        return message;
    },
};
function createBaseFileDescriptorResponse() {
    return {};
}
exports.FileDescriptorResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.file_descriptor_proto !== undefined && message.file_descriptor_proto.length !== 0) {
            for (const v of message.file_descriptor_proto) {
                writer.uint32(10).bytes(v);
            }
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseFileDescriptorResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    if (message.file_descriptor_proto === undefined) {
                        message.file_descriptor_proto = [];
                    }
                    const el = Buffer.from(reader.bytes());
                    if (el !== undefined) {
                        message.file_descriptor_proto.push(el);
                    }
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            file_descriptor_proto: globalThis.Array.isArray(object?.fileDescriptorProto)
                ? object.fileDescriptorProto.map((e) => Buffer.from(bytesFromBase64(e)))
                : globalThis.Array.isArray(object?.file_descriptor_proto)
                    ? object.file_descriptor_proto.map((e) => Buffer.from(bytesFromBase64(e)))
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.file_descriptor_proto?.length) {
            obj.fileDescriptorProto = message.file_descriptor_proto.map((e) => base64FromBytes(e));
        }
        return obj;
    },
    create(base) {
        return exports.FileDescriptorResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseFileDescriptorResponse();
        message.file_descriptor_proto = object.file_descriptor_proto?.map((e) => e) || undefined;
        return message;
    },
};
function createBaseExtensionNumberResponse() {
    return {};
}
exports.ExtensionNumberResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.base_type_name !== undefined && message.base_type_name !== "") {
            writer.uint32(10).string(message.base_type_name);
        }
        if (message.extension_number !== undefined && message.extension_number.length !== 0) {
            writer.uint32(18).fork();
            for (const v of message.extension_number) {
                writer.int32(v);
            }
            writer.join();
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseExtensionNumberResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    message.base_type_name = reader.string();
                    continue;
                }
                case 2: {
                    if (tag === 16) {
                        if (message.extension_number === undefined) {
                            message.extension_number = [];
                        }
                        message.extension_number.push(reader.int32());
                        continue;
                    }
                    if (tag === 18) {
                        if (message.extension_number === undefined) {
                            message.extension_number = [];
                        }
                        const end2 = reader.uint32() + reader.pos;
                        while (reader.pos < end2) {
                            message.extension_number.push(reader.int32());
                        }
                        continue;
                    }
                    break;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            base_type_name: isSet(object.baseTypeName)
                ? globalThis.String(object.baseTypeName)
                : isSet(object.base_type_name)
                    ? globalThis.String(object.base_type_name)
                    : undefined,
            extension_number: globalThis.Array.isArray(object?.extensionNumber)
                ? object.extensionNumber.map((e) => globalThis.Number(e))
                : globalThis.Array.isArray(object?.extension_number)
                    ? object.extension_number.map((e) => globalThis.Number(e))
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.base_type_name !== undefined && message.base_type_name !== "") {
            obj.baseTypeName = message.base_type_name;
        }
        if (message.extension_number?.length) {
            obj.extensionNumber = message.extension_number.map((e) => Math.round(e));
        }
        return obj;
    },
    create(base) {
        return exports.ExtensionNumberResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseExtensionNumberResponse();
        message.base_type_name = object.base_type_name ?? undefined;
        message.extension_number = object.extension_number?.map((e) => e) || undefined;
        return message;
    },
};
function createBaseListServiceResponse() {
    return {};
}
exports.ListServiceResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.service !== undefined && message.service.length !== 0) {
            for (const v of message.service) {
                exports.ServiceResponse.encode(v, writer.uint32(10).fork()).join();
            }
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseListServiceResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    if (message.service === undefined) {
                        message.service = [];
                    }
                    const el = exports.ServiceResponse.decode(reader, reader.uint32());
                    if (el !== undefined) {
                        message.service.push(el);
                    }
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            service: globalThis.Array.isArray(object?.service)
                ? object.service.map((e) => exports.ServiceResponse.fromJSON(e))
                : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.service?.length) {
            obj.service = message.service.map((e) => exports.ServiceResponse.toJSON(e));
        }
        return obj;
    },
    create(base) {
        return exports.ListServiceResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseListServiceResponse();
        message.service = object.service?.map((e) => exports.ServiceResponse.fromPartial(e)) || undefined;
        return message;
    },
};
function createBaseServiceResponse() {
    return {};
}
exports.ServiceResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.name !== undefined && message.name !== "") {
            writer.uint32(10).string(message.name);
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseServiceResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 10) {
                        break;
                    }
                    message.name = reader.string();
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return { name: isSet(object.name) ? globalThis.String(object.name) : undefined };
    },
    toJSON(message) {
        const obj = {};
        if (message.name !== undefined && message.name !== "") {
            obj.name = message.name;
        }
        return obj;
    },
    create(base) {
        return exports.ServiceResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseServiceResponse();
        message.name = object.name ?? undefined;
        return message;
    },
};
function createBaseErrorResponse() {
    return {};
}
exports.ErrorResponse = {
    encode(message, writer = new wire_1.BinaryWriter()) {
        if (message.error_code !== undefined && message.error_code !== 0) {
            writer.uint32(8).int32(message.error_code);
        }
        if (message.error_message !== undefined && message.error_message !== "") {
            writer.uint32(18).string(message.error_message);
        }
        return writer;
    },
    decode(input, length) {
        const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
        const end = length === undefined ? reader.len : reader.pos + length;
        const message = createBaseErrorResponse();
        while (reader.pos < end) {
            const tag = reader.uint32();
            switch (tag >>> 3) {
                case 1: {
                    if (tag !== 8) {
                        break;
                    }
                    message.error_code = reader.int32();
                    continue;
                }
                case 2: {
                    if (tag !== 18) {
                        break;
                    }
                    message.error_message = reader.string();
                    continue;
                }
            }
            if ((tag & 7) === 4 || tag === 0) {
                break;
            }
            reader.skip(tag & 7);
        }
        return message;
    },
    fromJSON(object) {
        return {
            error_code: isSet(object.errorCode)
                ? globalThis.Number(object.errorCode)
                : isSet(object.error_code)
                    ? globalThis.Number(object.error_code)
                    : undefined,
            error_message: isSet(object.errorMessage)
                ? globalThis.String(object.errorMessage)
                : isSet(object.error_message)
                    ? globalThis.String(object.error_message)
                    : undefined,
        };
    },
    toJSON(message) {
        const obj = {};
        if (message.error_code !== undefined && message.error_code !== 0) {
            obj.errorCode = Math.round(message.error_code);
        }
        if (message.error_message !== undefined && message.error_message !== "") {
            obj.errorMessage = message.error_message;
        }
        return obj;
    },
    create(base) {
        return exports.ErrorResponse.fromPartial(base ?? {});
    },
    fromPartial(object) {
        const message = createBaseErrorResponse();
        message.error_code = object.error_code ?? undefined;
        message.error_message = object.error_message ?? undefined;
        return message;
    },
};
exports.ServerReflectionDefinition = {
    name: "ServerReflection",
    fullName: "grpc.reflection.v1.ServerReflection",
    methods: {
        /**
         * The reflection service is structured as a bidirectional stream, ensuring
         * all related requests go to a single server.
         */
        serverReflectionInfo: {
            name: "ServerReflectionInfo",
            requestType: exports.ServerReflectionRequest,
            requestStream: true,
            responseType: exports.ServerReflectionResponse,
            responseStream: true,
            options: {},
        },
    },
};
exports.protoMetadata = {
    fileDescriptor: {
        "name": "grpc/reflection/v1/reflection.proto",
        "package": "grpc.reflection.v1",
        "dependency": [],
        "publicDependency": [],
        "weakDependency": [],
        "optionDependency": [],
        "messageType": [{
                "name": "ServerReflectionRequest",
                "field": [{
                        "name": "host",
                        "number": 1,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "host",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "file_by_filename",
                        "number": 3,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "fileByFilename",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "file_containing_symbol",
                        "number": 4,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "fileContainingSymbol",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "file_containing_extension",
                        "number": 5,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ExtensionRequest",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "fileContainingExtension",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "all_extension_numbers_of_type",
                        "number": 6,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "allExtensionNumbersOfType",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "list_services",
                        "number": 7,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "listServices",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [{ "name": "message_request", "options": undefined }],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ExtensionRequest",
                "field": [{
                        "name": "containing_type",
                        "number": 1,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "containingType",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "extension_number",
                        "number": 2,
                        "label": 1,
                        "type": 5,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "extensionNumber",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ServerReflectionResponse",
                "field": [{
                        "name": "valid_host",
                        "number": 1,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "validHost",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "original_request",
                        "number": 2,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ServerReflectionRequest",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "originalRequest",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "file_descriptor_response",
                        "number": 4,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.FileDescriptorResponse",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "fileDescriptorResponse",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "all_extension_numbers_response",
                        "number": 5,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ExtensionNumberResponse",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "allExtensionNumbersResponse",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "list_services_response",
                        "number": 6,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ListServiceResponse",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "listServicesResponse",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "error_response",
                        "number": 7,
                        "label": 1,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ErrorResponse",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "errorResponse",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [{ "name": "message_response", "options": undefined }],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "FileDescriptorResponse",
                "field": [{
                        "name": "file_descriptor_proto",
                        "number": 1,
                        "label": 3,
                        "type": 12,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "fileDescriptorProto",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ExtensionNumberResponse",
                "field": [{
                        "name": "base_type_name",
                        "number": 1,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "baseTypeName",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "extension_number",
                        "number": 2,
                        "label": 3,
                        "type": 5,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "extensionNumber",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ListServiceResponse",
                "field": [{
                        "name": "service",
                        "number": 1,
                        "label": 3,
                        "type": 11,
                        "typeName": ".grpc.reflection.v1.ServiceResponse",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "service",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ServiceResponse",
                "field": [{
                        "name": "name",
                        "number": 1,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "name",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }, {
                "name": "ErrorResponse",
                "field": [{
                        "name": "error_code",
                        "number": 1,
                        "label": 1,
                        "type": 5,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "errorCode",
                        "options": undefined,
                        "proto3Optional": false,
                    }, {
                        "name": "error_message",
                        "number": 2,
                        "label": 1,
                        "type": 9,
                        "typeName": "",
                        "extendee": "",
                        "defaultValue": "",
                        "oneofIndex": 0,
                        "jsonName": "errorMessage",
                        "options": undefined,
                        "proto3Optional": false,
                    }],
                "extension": [],
                "nestedType": [],
                "enumType": [],
                "extensionRange": [],
                "oneofDecl": [],
                "options": undefined,
                "reservedRange": [],
                "reservedName": [],
                "visibility": 0,
            }],
        "enumType": [],
        "service": [{
                "name": "ServerReflection",
                "method": [{
                        "name": "ServerReflectionInfo",
                        "inputType": ".grpc.reflection.v1.ServerReflectionRequest",
                        "outputType": ".grpc.reflection.v1.ServerReflectionResponse",
                        "options": undefined,
                        "clientStreaming": true,
                        "serverStreaming": true,
                    }],
                "options": undefined,
            }],
        "extension": [],
        "options": {
            "javaPackage": "io.grpc.reflection.v1",
            "javaOuterClassname": "ServerReflectionProto",
            "javaMultipleFiles": true,
            "javaGenerateEqualsAndHash": false,
            "javaStringCheckUtf8": false,
            "optimizeFor": 1,
            "goPackage": "google.golang.org/grpc/reflection/grpc_reflection_v1",
            "ccGenericServices": false,
            "javaGenericServices": false,
            "pyGenericServices": false,
            "deprecated": false,
            "ccEnableArenas": true,
            "objcClassPrefix": "",
            "csharpNamespace": "",
            "swiftPrefix": "",
            "phpClassPrefix": "",
            "phpNamespace": "",
            "phpMetadataNamespace": "",
            "rubyPackage": "",
            "features": undefined,
            "uninterpretedOption": [],
        },
        "sourceCodeInfo": {
            "location": [{
                    "path": [6, 0, 2, 0],
                    "span": [33, 2, 34, 48],
                    "leadingComments": " The reflection service is structured as a bidirectional stream, ensuring\n all related requests go to a single server.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0],
                    "span": [38, 0, 70, 1],
                    "leadingComments": " The message sent by the client when calling ServerReflectionInfo method.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 8, 0],
                    "span": [43, 2, 69, 3],
                    "leadingComments": " To use reflection service, the client should set one of the following\n fields in message_request. The server distinguishes requests by their\n defined field and then handles them using corresponding methods.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 2, 1],
                    "span": [45, 4, 32],
                    "leadingComments": " Find a proto file by the file name.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 2, 2],
                    "span": [50, 4, 38],
                    "leadingComments": " Find the proto file that declares the given fully-qualified symbol name.\n This field should be a fully-qualified symbol name\n (e.g. <package>.<service>[.<method>] or <package>.<type>).\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 2, 3],
                    "span": [54, 4, 51],
                    "leadingComments": " Find the proto file which defines an extension extending the given\n message type with the given field number.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 2, 4],
                    "span": [64, 4, 45],
                    "leadingComments": " Finds the tag numbers used by all known extensions of the given message\n type, and appends them to ExtensionNumberResponse in an undefined order.\n Its corresponding method is best-effort: it's not guaranteed that the\n reflection service will implement this method, and it's not guaranteed\n that this method will provide all extensions. Returns\n StatusCode::UNIMPLEMENTED if it's not implemented.\n This field should be a fully-qualified type name. The format is\n <package>.<type>\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 0, 2, 5],
                    "span": [68, 4, 29],
                    "leadingComments": " List the full names of registered services. The content will not be\n checked.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 1],
                    "span": [74, 0, 78, 1],
                    "leadingComments": " The type name and extension number sent by the client when requesting\n file_containing_extension.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 1, 2, 0],
                    "span": [76, 2, 29],
                    "leadingComments": " Fully-qualified type name. The format should be <package>.<type>\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2],
                    "span": [81, 0, 104, 1],
                    "leadingComments": " The message sent by the server to answer ServerReflectionInfo method.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2, 8, 0],
                    "span": [86, 2, 103, 3],
                    "leadingComments": " The server sets one of the following fields according to the message_request\n in the request.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2, 2, 2],
                    "span": [93, 4, 56],
                    "leadingComments": " This message is used to answer file_by_filename, file_containing_symbol,\n file_containing_extension requests with transitive dependencies.\n As the repeated label is not allowed in oneof fields, we use a\n FileDescriptorResponse message to encapsulate the repeated fields.\n The reflection service is allowed to avoid sending FileDescriptorProtos\n that were previously sent in response to earlier requests in the stream.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2, 2, 3],
                    "span": [96, 4, 63],
                    "leadingComments": " This message is used to answer all_extension_numbers_of_type requests.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2, 2, 4],
                    "span": [99, 4, 51],
                    "leadingComments": " This message is used to answer list_services requests.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 2, 2, 5],
                    "span": [102, 4, 37],
                    "leadingComments": " This message is used when an error occurs.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 3],
                    "span": [109, 0, 114, 1],
                    "leadingComments": " Serialized FileDescriptorProto messages sent by the server answering\n a file_by_filename, file_containing_symbol, or file_containing_extension\n request.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 3, 2, 0],
                    "span": [113, 2, 43],
                    "leadingComments": " Serialized FileDescriptorProto messages. We avoid taking a dependency on\n descriptor.proto, which uses proto2 only features, by making them opaque\n bytes instead.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 4],
                    "span": [118, 0, 123, 1],
                    "leadingComments": " A list of extension numbers sent by the server answering\n all_extension_numbers_of_type request.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 4, 2, 0],
                    "span": [121, 2, 28],
                    "leadingComments": " Full name of the base type, including the package name. The format\n is <package>.<type>\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 5],
                    "span": [126, 0, 130, 1],
                    "leadingComments": " A list of ServiceResponse sent by the server answering list_services request.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 5, 2, 0],
                    "span": [129, 2, 39],
                    "leadingComments": " The information of each service may be expanded in the future, so we use\n ServiceResponse message to encapsulate it.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 6],
                    "span": [134, 0, 138, 1],
                    "leadingComments": " The information of a single service used by ListServiceResponse to answer\n list_services request.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 6, 2, 0],
                    "span": [137, 2, 18],
                    "leadingComments": " Full name of a registered service, including its package name. The format\n is <package>.<service>\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 7],
                    "span": [141, 0, 145, 1],
                    "leadingComments": " The error code and error message sent by the server when an error occurs.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }, {
                    "path": [4, 7, 2, 0],
                    "span": [143, 2, 23],
                    "leadingComments": " This field uses the error codes defined in grpc::StatusCode.\n",
                    "trailingComments": "",
                    "leadingDetachedComments": [],
                }],
        },
        "syntax": "proto3",
        "edition": 0,
    },
    references: {
        ".grpc.reflection.v1.ServerReflectionRequest": exports.ServerReflectionRequest,
        ".grpc.reflection.v1.ExtensionRequest": exports.ExtensionRequest,
        ".grpc.reflection.v1.ServerReflectionResponse": exports.ServerReflectionResponse,
        ".grpc.reflection.v1.FileDescriptorResponse": exports.FileDescriptorResponse,
        ".grpc.reflection.v1.ExtensionNumberResponse": exports.ExtensionNumberResponse,
        ".grpc.reflection.v1.ListServiceResponse": exports.ListServiceResponse,
        ".grpc.reflection.v1.ServiceResponse": exports.ServiceResponse,
        ".grpc.reflection.v1.ErrorResponse": exports.ErrorResponse,
    },
    dependencies: [],
};
function bytesFromBase64(b64) {
    return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
}
function base64FromBytes(arr) {
    return globalThis.Buffer.from(arr).toString("base64");
}
function isSet(value) {
    return value !== null && value !== undefined;
}
//# sourceMappingURL=reflection.js.map