Functions | Variables
reflection.c File Reference
#include "upb/reflection.h"
#include <string.h>
#include "upb/msg.h"
#include "upb/port_def.inc"
#include "upb/table_internal.h"
Include dependency graph for reflection.c:

Go to the source code of this file.

Functions

bool _upb_Message_DiscardUnknown (upb_Message *msg, const upb_MessageDef *m, int depth)
 
static upb_MessageValue _upb_Message_Getraw (const upb_Message *msg, const upb_FieldDef *f)
 
static size_t get_field_size (const upb_MiniTable_Field *f)
 
static bool in_oneof (const upb_MiniTable_Field *field)
 
bool upb_Array_Append (upb_Array *arr, upb_MessageValue val, upb_Arena *arena)
 
void upb_Array_Delete (upb_Array *arr, size_t i, size_t count)
 
upb_MessageValue upb_Array_Get (const upb_Array *arr, size_t i)
 
bool upb_Array_Insert (upb_Array *arr, size_t i, size_t count, upb_Arena *arena)
 
void upb_Array_Move (upb_Array *arr, size_t dst_idx, size_t src_idx, size_t count)
 
upb_Arrayupb_Array_New (upb_Arena *a, upb_CType type)
 
bool upb_Array_Resize (upb_Array *arr, size_t size, upb_Arena *arena)
 
void upb_Array_Set (upb_Array *arr, size_t i, upb_MessageValue val)
 
size_t upb_Array_Size (const upb_Array *arr)
 
void upb_Map_Clear (upb_Map *map)
 
bool upb_Map_Delete (upb_Map *map, upb_MessageValue key)
 
bool upb_Map_Get (const upb_Map *map, upb_MessageValue key, upb_MessageValue *val)
 
upb_Mapupb_Map_New (upb_Arena *a, upb_CType key_type, upb_CType value_type)
 
bool upb_Map_Set (upb_Map *map, upb_MessageValue key, upb_MessageValue val, upb_Arena *arena)
 
size_t upb_Map_Size (const upb_Map *map)
 
bool upb_MapIterator_Done (const upb_Map *map, size_t iter)
 
upb_MessageValue upb_MapIterator_Key (const upb_Map *map, size_t iter)
 
bool upb_MapIterator_Next (const upb_Map *map, size_t *iter)
 
upb_MessageValue upb_MapIterator_Value (const upb_Map *map, size_t iter)
 
void upb_Message_Clear (upb_Message *msg, const upb_MessageDef *m)
 
void upb_Message_ClearField (upb_Message *msg, const upb_FieldDef *f)
 
bool upb_Message_DiscardUnknown (upb_Message *msg, const upb_MessageDef *m, int maxdepth)
 
upb_MessageValue upb_Message_Get (const upb_Message *msg, const upb_FieldDef *f)
 
bool upb_Message_Has (const upb_Message *msg, const upb_FieldDef *f)
 
upb_MutableMessageValue upb_Message_Mutable (upb_Message *msg, const upb_FieldDef *f, upb_Arena *a)
 
upb_Messageupb_Message_New (const upb_MessageDef *m, upb_Arena *a)
 
bool upb_Message_Next (const upb_Message *msg, const upb_MessageDef *m, const upb_DefPool *ext_pool, const upb_FieldDef **out_f, upb_MessageValue *out_val, size_t *iter)
 
bool upb_Message_Set (upb_Message *msg, const upb_FieldDef *f, upb_MessageValue val, upb_Arena *a)
 
const upb_FieldDefupb_Message_WhichOneof (const upb_Message *msg, const upb_OneofDef *o)
 

Variables

static char _upb_CTypeo_mapsize [12]
 
static const char _upb_CTypeo_sizelg2 [12]
 

Function Documentation

◆ _upb_Message_DiscardUnknown()

bool _upb_Message_DiscardUnknown ( upb_Message msg,
const upb_MessageDef m,
int  depth 
)

Definition at line 301 of file reflection.c.

◆ _upb_Message_Getraw()

static upb_MessageValue _upb_Message_Getraw ( const upb_Message msg,
const upb_FieldDef f 
)
static

Definition at line 103 of file reflection.c.

◆ get_field_size()

static size_t get_field_size ( const upb_MiniTable_Field f)
static

Definition at line 36 of file reflection.c.

◆ in_oneof()

static bool in_oneof ( const upb_MiniTable_Field field)
static

Definition at line 99 of file reflection.c.

◆ upb_Array_Append()

bool upb_Array_Append ( upb_Array arr,
upb_MessageValue  val,
upb_Arena arena 
)

Definition at line 380 of file reflection.c.

◆ upb_Array_Delete()

void upb_Array_Delete ( upb_Array arr,
size_t  i,
size_t  count 
)

Definition at line 411 of file reflection.c.

◆ upb_Array_Get()

upb_MessageValue upb_Array_Get ( const upb_Array arr,
size_t  i 
)

Definition at line 364 of file reflection.c.

◆ upb_Array_Insert()

bool upb_Array_Insert ( upb_Array arr,
size_t  i,
size_t  count,
upb_Arena arena 
)

Definition at line 395 of file reflection.c.

◆ upb_Array_Move()

void upb_Array_Move ( upb_Array arr,
size_t  dst_idx,
size_t  src_idx,
size_t  count 
)

Definition at line 388 of file reflection.c.

◆ upb_Array_New()

upb_Array* upb_Array_New ( upb_Arena a,
upb_CType  type 
)

upb_Array

Definition at line 358 of file reflection.c.

◆ upb_Array_Resize()

bool upb_Array_Resize ( upb_Array arr,
size_t  size,
upb_Arena arena 
)

Definition at line 419 of file reflection.c.

◆ upb_Array_Set()

void upb_Array_Set ( upb_Array arr,
size_t  i,
upb_MessageValue  val 
)

Definition at line 373 of file reflection.c.

◆ upb_Array_Size()

size_t upb_Array_Size ( const upb_Array arr)

Definition at line 362 of file reflection.c.

◆ upb_Map_Clear()

void upb_Map_Clear ( upb_Map map)

Definition at line 437 of file reflection.c.

◆ upb_Map_Delete()

bool upb_Map_Delete ( upb_Map map,
upb_MessageValue  key 
)

Definition at line 444 of file reflection.c.

◆ upb_Map_Get()

bool upb_Map_Get ( const upb_Map map,
upb_MessageValue  key,
upb_MessageValue val 
)

Definition at line 432 of file reflection.c.

◆ upb_Map_New()

upb_Map* upb_Map_New ( upb_Arena a,
upb_CType  key_type,
upb_CType  value_type 
)

upb_Map

Definition at line 425 of file reflection.c.

◆ upb_Map_Set()

bool upb_Map_Set ( upb_Map map,
upb_MessageValue  key,
upb_MessageValue  val,
upb_Arena arena 
)

Definition at line 439 of file reflection.c.

◆ upb_Map_Size()

size_t upb_Map_Size ( const upb_Map map)

Definition at line 430 of file reflection.c.

◆ upb_MapIterator_Done()

bool upb_MapIterator_Done ( const upb_Map map,
size_t  iter 
)

Definition at line 452 of file reflection.c.

◆ upb_MapIterator_Key()

upb_MessageValue upb_MapIterator_Key ( const upb_Map map,
size_t  iter 
)

Definition at line 461 of file reflection.c.

◆ upb_MapIterator_Next()

bool upb_MapIterator_Next ( const upb_Map map,
size_t *  iter 
)

Definition at line 448 of file reflection.c.

◆ upb_MapIterator_Value()

upb_MessageValue upb_MapIterator_Value ( const upb_Map map,
size_t  iter 
)

Definition at line 470 of file reflection.c.

◆ upb_Message_Clear()

void upb_Message_Clear ( upb_Message msg,
const upb_MessageDef m 
)

Definition at line 241 of file reflection.c.

◆ upb_Message_ClearField()

void upb_Message_ClearField ( upb_Message msg,
const upb_FieldDef f 
)

Definition at line 222 of file reflection.c.

◆ upb_Message_DiscardUnknown()

bool upb_Message_DiscardUnknown ( upb_Message msg,
const upb_MessageDef m,
int  maxdepth 
)

Definition at line 351 of file reflection.c.

◆ upb_Message_Get()

upb_MessageValue upb_Message_Get ( const upb_Message msg,
const upb_FieldDef f 
)

Definition at line 146 of file reflection.c.

◆ upb_Message_Has()

bool upb_Message_Has ( const upb_Message msg,
const upb_FieldDef f 
)

Definition at line 112 of file reflection.c.

◆ upb_Message_Mutable()

upb_MutableMessageValue upb_Message_Mutable ( upb_Message msg,
const upb_FieldDef f,
upb_Arena a 
)

Definition at line 164 of file reflection.c.

◆ upb_Message_New()

upb_Message* upb_Message_New ( const upb_MessageDef m,
upb_Arena a 
)

upb_Message

Definition at line 95 of file reflection.c.

◆ upb_Message_Next()

bool upb_Message_Next ( const upb_Message msg,
const upb_MessageDef m,
const upb_DefPool ext_pool,
const upb_FieldDef **  out_f,
upb_MessageValue out_val,
size_t *  iter 
)

Definition at line 245 of file reflection.c.

◆ upb_Message_Set()

bool upb_Message_Set ( upb_Message msg,
const upb_FieldDef f,
upb_MessageValue  val,
upb_Arena a 
)

Definition at line 202 of file reflection.c.

◆ upb_Message_WhichOneof()

const upb_FieldDef* upb_Message_WhichOneof ( const upb_Message msg,
const upb_OneofDef o 
)

Definition at line 131 of file reflection.c.

Variable Documentation

◆ _upb_CTypeo_mapsize

char _upb_CTypeo_mapsize[12]
static
Initial value:
= {
0,
1,
4,
4,
4,
4,
sizeof(void*),
8,
8,
8,
0,
0,
}

Definition at line 62 of file reflection.c.

◆ _upb_CTypeo_sizelg2

const char _upb_CTypeo_sizelg2[12]
static
Initial value:
= {
0,
0,
2,
2,
2,
2,
UPB_SIZE(2, 3),
3,
3,
3,
UPB_SIZE(3, 4),
UPB_SIZE(3, 4),
}

Definition at line 77 of file reflection.c.

UPB_SIZE
#define UPB_SIZE(size32, size64)
Definition: bloaty/third_party/protobuf/php/ext/google/protobuf/upb.c:32


grpc
Author(s):
autogenerated on Fri May 16 2025 03:01:27