This commit is contained in:
Yao
2024-12-20 17:49:45 +08:00
parent 86b0363ce1
commit 654d456c7d
7011 changed files with 1705926 additions and 7 deletions

View File

@@ -0,0 +1,72 @@
/*
* Copyright 2023 Google LLC
*
* 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.
*/
/* Automatically generated nanopb constant definitions */
/* Generated by nanopb-0.3.9.8 */
#include "status.nanopb.h"
#include "Firestore/core/src/nanopb/pretty_printing.h"
namespace firebase {
namespace firestore {
using nanopb::PrintEnumField;
using nanopb::PrintHeader;
using nanopb::PrintMessageField;
using nanopb::PrintPrimitiveField;
using nanopb::PrintTail;
/* @@protoc_insertion_point(includes) */
#if PB_PROTO_HEADER_VERSION != 30
#error Regenerate this file with the current version of nanopb generator.
#endif
const pb_field_t google_rpc_Status_fields[4] = {
PB_FIELD( 1, INT32 , SINGULAR, STATIC , FIRST, google_rpc_Status, code, code, 0),
PB_FIELD( 2, BYTES , SINGULAR, POINTER , OTHER, google_rpc_Status, message, code, 0),
PB_FIELD( 3, MESSAGE , REPEATED, POINTER , OTHER, google_rpc_Status, details, message, &google_protobuf_Any_fields),
PB_LAST_FIELD
};
std::string google_rpc_Status::ToString(int indent) const {
std::string tostring_header = PrintHeader(indent, "Status", this);
std::string tostring_result;
tostring_result += PrintPrimitiveField("code: ", code, indent + 1, false);
tostring_result += PrintPrimitiveField("message: ",
message, indent + 1, false);
for (pb_size_t i = 0; i != details_count; ++i) {
tostring_result += PrintMessageField("details ",
details[i], indent + 1, true);
}
bool is_root = indent == 0;
if (!tostring_result.empty() || is_root) {
std::string tostring_tail = PrintTail(indent);
return tostring_header + tostring_result + tostring_tail;
} else {
return "";
}
}
} // namespace firestore
} // namespace firebase
/* @@protoc_insertion_point(eof) */

View File

@@ -0,0 +1,78 @@
/*
* Copyright 2023 Google LLC
*
* 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.
*/
/* Automatically generated nanopb header */
/* Generated by nanopb-0.3.9.8 */
#ifndef PB_GOOGLE_RPC_STATUS_NANOPB_H_INCLUDED
#define PB_GOOGLE_RPC_STATUS_NANOPB_H_INCLUDED
#include <pb.h>
#include "google/protobuf/any.nanopb.h"
#include <string>
namespace firebase {
namespace firestore {
/* @@protoc_insertion_point(includes) */
#if PB_PROTO_HEADER_VERSION != 30
#error Regenerate this file with the current version of nanopb generator.
#endif
/* Struct definitions */
typedef struct _google_rpc_Status {
int32_t code;
pb_bytes_array_t *message;
pb_size_t details_count;
struct _google_protobuf_Any *details;
std::string ToString(int indent = 0) const;
/* @@protoc_insertion_point(struct:google_rpc_Status) */
} google_rpc_Status;
/* Default values for struct fields */
/* Initializer values for message structs */
#define google_rpc_Status_init_default {0, NULL, 0, NULL}
#define google_rpc_Status_init_zero {0, NULL, 0, NULL}
/* Field tags (for use in manual encoding/decoding) */
#define google_rpc_Status_code_tag 1
#define google_rpc_Status_message_tag 2
#define google_rpc_Status_details_tag 3
/* Struct field encoding specification for nanopb */
extern const pb_field_t google_rpc_Status_fields[4];
/* Maximum encoded size of messages (where known) */
/* google_rpc_Status_size depends on runtime parameters */
/* Message IDs (where set with "msgid" option) */
#ifdef PB_MSGID
#define STATUS_MESSAGES \
#endif
} // namespace firestore
} // namespace firebase
/* @@protoc_insertion_point(eof) */
#endif