Protocol Buffers - Google's data interchange format (grpc依赖)
https://developers.google.com/protocol-buffers/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
2.0 KiB
58 lines
2.0 KiB
1 year ago
|
// Protocol Buffers - Google's data interchange format
|
||
|
// Copyright 2023 Google LLC. All rights reserved.
|
||
|
//
|
||
1 year ago
|
// Use of this source code is governed by a BSD-style
|
||
|
// license that can be found in the LICENSE file or at
|
||
|
// https://developers.google.com/open-source/licenses/bsd
|
||
2 years ago
|
|
||
2 years ago
|
#ifndef UPB_REFLECTION_DEF_POOL_INTERNAL_H_
|
||
|
#define UPB_REFLECTION_DEF_POOL_INTERNAL_H_
|
||
2 years ago
|
|
||
1 year ago
|
#include "upb/mini_descriptor/decode.h"
|
||
|
#include "upb/reflection/def_pool.h"
|
||
2 years ago
|
|
||
|
// Must be last.
|
||
1 year ago
|
#include "upb/port/def.inc"
|
||
2 years ago
|
|
||
|
#ifdef __cplusplus
|
||
|
extern "C" {
|
||
|
#endif
|
||
|
|
||
2 years ago
|
upb_Arena* _upb_DefPool_Arena(const upb_DefPool* s);
|
||
|
size_t _upb_DefPool_BytesLoaded(const upb_DefPool* s);
|
||
|
upb_ExtensionRegistry* _upb_DefPool_ExtReg(const upb_DefPool* s);
|
||
|
|
||
2 years ago
|
bool _upb_DefPool_InsertExt(upb_DefPool* s, const upb_MiniTableExtension* ext,
|
||
2 years ago
|
const upb_FieldDef* f);
|
||
2 years ago
|
bool _upb_DefPool_InsertSym(upb_DefPool* s, upb_StringView sym, upb_value v,
|
||
|
upb_Status* status);
|
||
|
bool _upb_DefPool_LookupSym(const upb_DefPool* s, const char* sym, size_t size,
|
||
|
upb_value* v);
|
||
|
|
||
|
void** _upb_DefPool_ScratchData(const upb_DefPool* s);
|
||
|
size_t* _upb_DefPool_ScratchSize(const upb_DefPool* s);
|
||
2 years ago
|
void _upb_DefPool_SetPlatform(upb_DefPool* s, upb_MiniTablePlatform platform);
|
||
2 years ago
|
|
||
|
// For generated code only: loads a generated descriptor.
|
||
|
typedef struct _upb_DefPool_Init {
|
||
|
struct _upb_DefPool_Init** deps; // Dependencies of this file.
|
||
2 years ago
|
const upb_MiniTableFile* layout;
|
||
2 years ago
|
const char* filename;
|
||
|
upb_StringView descriptor; // Serialized descriptor.
|
||
|
} _upb_DefPool_Init;
|
||
|
|
||
|
bool _upb_DefPool_LoadDefInit(upb_DefPool* s, const _upb_DefPool_Init* init);
|
||
2 years ago
|
|
||
2 years ago
|
// Should only be directly called by tests. This variant lets us suppress
|
||
|
// the use of compiled-in tables, forcing a rebuild of the tables at runtime.
|
||
|
bool _upb_DefPool_LoadDefInitEx(upb_DefPool* s, const _upb_DefPool_Init* init,
|
||
|
bool rebuild_minitable);
|
||
2 years ago
|
|
||
2 years ago
|
#ifdef __cplusplus
|
||
|
} /* extern "C" */
|
||
|
#endif
|
||
|
|
||
1 year ago
|
#include "upb/port/undef.inc"
|
||
2 years ago
|
|
||
2 years ago
|
#endif /* UPB_REFLECTION_DEF_POOL_INTERNAL_H_ */
|