#include "protobuf.h"
Go to the source code of this file.
Classes | |
struct | field_handlerdata_t |
struct | map_handlerdata_t |
struct | map_parse_frame_t |
struct | oneof_handlerdata_t |
struct | stackenv |
struct | submsg_handlerdata_t |
Macros | |
#define | DEFINE_APPEND_HANDLER(type, ctype) |
#define | DEFINE_ONEOF_HANDLER(type, ctype) |
#define | DEREF(msg, ofs, type) *(type*)(((uint8_t *)msg) + ofs) |
#define | SET_HANDLER(utype, ltype) |
#define | SET_HANDLER(utype, ltype) |
#define | STACK_ENV_STACKBYTES 4096 |
#define | T(upbtypeconst, upbtype, ctype) |
#define | T(upbtypeconst, upbtype, ctype, default_value) |
Functions | |
static void | add_handlers_for_mapentry (const upb_msgdef *msgdef, upb_handlers *h, Descriptor *desc) |
static void | add_handlers_for_mapfield (upb_handlers *h, const upb_fielddef *fielddef, size_t offset, Descriptor *desc) |
static void | add_handlers_for_message (const void *closure, upb_handlers *h) |
static void | add_handlers_for_oneof_field (upb_handlers *h, const upb_fielddef *f, size_t offset, size_t oneof_case_offset) |
static void | add_handlers_for_repeated_field (upb_handlers *h, const upb_fielddef *f, size_t offset) |
static void | add_handlers_for_singular_field (upb_handlers *h, const upb_fielddef *f, size_t offset, size_t hasbit_off) |
static void * | appendbytes_handler (void *closure, const void *hd, size_t size_hint) |
static void * | appendstr_handler (void *closure, const void *hd, size_t size_hint) |
static bool | appendstring_end_handler (void *closure, const void *hd) |
static void * | appendsubmsg_handler (void *closure, const void *hd) |
static void * | bytes_handler (void *closure, const void *hd, size_t size_hint) |
static void | discard_unknown (VALUE msg_rb, const Descriptor *desc) |
static bool | endmap_handler (void *closure, const void *hd, upb_status *s) |
static bool | env_error_func (void *ud, const upb_status *status) |
const upb_handlers * | get_fill_handlers (Descriptor *desc) |
static upb_selector_t | getsel (const upb_fielddef *f, upb_handlertype_t type) |
VALUE | Google_Protobuf_discard_unknown (VALUE self, VALUE msg_rb) |
static map_parse_frame_t * | map_push_frame (VALUE map, const map_handlerdata_t *handlerdata) |
void | MapParseFrame_free (void *self) |
static void | MapParseFrame_mark (void *_self) |
VALUE | Message_decode (VALUE klass, VALUE data) |
VALUE | Message_decode_json (int argc, VALUE *argv, VALUE klass) |
VALUE | Message_encode (VALUE klass, VALUE msg_rb) |
VALUE | Message_encode_json (int argc, VALUE *argv, VALUE klass) |
static const upb_pbdecodermethod * | msgdef_decodermethod (Descriptor *desc) |
static const upb_handlers * | msgdef_json_serialize_handlers (Descriptor *desc, bool preserve_proto_fieldnames) |
static const upb_json_parsermethod * | msgdef_jsonparsermethod (Descriptor *desc) |
static const upb_handlers * | msgdef_pb_serialize_handlers (Descriptor *desc) |
static const upb_handlers * | new_fill_handlers (Descriptor *desc, const void *owner) |
const upb_pbdecodermethod * | new_fillmsg_decodermethod (Descriptor *desc, const void *owner) |
static map_handlerdata_t * | new_map_handlerdata (size_t ofs, const upb_msgdef *mapentry_def, Descriptor *desc) |
static const void * | newhandlerdata (upb_handlers *h, uint32_t ofs, int32_t hasbit) |
static const void * | newoneofhandlerdata (upb_handlers *h, uint32_t ofs, uint32_t case_ofs, const upb_fielddef *f) |
static const void * | newsubmsghandlerdata (upb_handlers *h, uint32_t ofs, int32_t hasbit, const upb_fielddef *f) |
VALUE | noleak_rb_str_cat (VALUE rb_str, const char *str, long len) |
static void * | oneofbytes_handler (void *closure, const void *hd, size_t size_hint) |
static void * | oneofstr_handler (void *closure, const void *hd, size_t size_hint) |
static bool | oneofstring_end_handler (void *closure, const void *hd) |
static void * | oneofsubmsg_handler (void *closure, const void *hd) |
static void | put_ruby_value (VALUE value, const upb_fielddef *f, VALUE type_class, int depth, upb_sink *sink, bool emit_defaults, bool is_json) |
static void | putary (VALUE ary, const upb_fielddef *f, upb_sink *sink, int depth, bool emit_defaults, bool is_json) |
static void | putjsonany (VALUE msg_rb, const Descriptor *desc, upb_sink *sink, int depth, bool emit_defaults) |
static void | putjsonlistvalue (VALUE msg_rb, const Descriptor *desc, upb_sink *sink, int depth, bool emit_defaults) |
static void | putmap (VALUE map, const upb_fielddef *f, upb_sink *sink, int depth, bool emit_defaults, bool is_json) |
static void | putmsg (VALUE msg, const Descriptor *desc, upb_sink *sink, int depth, bool emit_defaults, bool is_json, bool open_msg) |
static void | putstr (VALUE str, const upb_fielddef *f, upb_sink *sink) |
static void | putsubmsg (VALUE submsg, const upb_fielddef *f, upb_sink *sink, int depth, bool emit_defaults, bool is_json) |
static void | set_hasbit (void *closure, int32_t hasbit) |
static void | stackenv_init (stackenv *se, const char *errmsg) |
static void | stackenv_uninit (stackenv *se) |
static void * | startmapentry_handler (void *closure, const void *hd) |
static void * | startseq_handler (void *closure, const void *hd) |
static void * | str_handler (void *closure, const void *hd, size_t size_hint) |
static bool | stringdata_end_handler (void *closure, const void *hd) |
static size_t | stringdata_handler (void *closure, const void *hd, const char *str, size_t len, const upb_bufhandle *handle) |
void | stringsink_init (stringsink *sink) |
static void * | stringsink_start (void *_sink, const void *hd, size_t size_hint) |
static size_t | stringsink_string (void *_sink, const void *hd, const char *ptr, size_t len, const upb_bufhandle *handle) |
void | stringsink_uninit (stringsink *sink) |
static void * | submsg_handler (void *closure, const void *hd) |
static bool | unknown_field_handler (void *closure, const void *hd, const char *buf, size_t size) |
Variables | |
rb_data_type_t | MapParseFrame_type |
#define DEFINE_APPEND_HANDLER | ( | type, | |
ctype | |||
) |
#define DEFINE_ONEOF_HANDLER | ( | type, | |
ctype | |||
) |
Definition at line 434 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 101 of file ruby/ext/google/protobuf_c/encode_decode.c.
#define SET_HANDLER | ( | utype, | |
ltype | |||
) |
#define SET_HANDLER | ( | utype, | |
ltype | |||
) |
#define STACK_ENV_STACKBYTES 4096 |
Definition at line 813 of file ruby/ext/google/protobuf_c/encode_decode.c.
#define T | ( | upbtypeconst, | |
upbtype, | |||
ctype | |||
) |
#define T | ( | upbtypeconst, | |
upbtype, | |||
ctype, | |||
default_value | |||
) |
|
static |
Definition at line 630 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 615 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 714 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 653 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 520 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 567 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 210 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 192 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 262 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 269 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 235 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1530 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 378 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 824 of file ruby/ext/google/protobuf_c/encode_decode.c.
const upb_handlers* get_fill_handlers | ( | Descriptor * | desc | ) |
Definition at line 773 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 963 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE Google_Protobuf_discard_unknown | ( | VALUE | self, |
VALUE | msg_rb | ||
) |
Definition at line 1607 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 352 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 343 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 332 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE Message_decode | ( | VALUE | klass, |
VALUE | data | ||
) |
Definition at line 856 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE Message_decode_json | ( | int | argc, |
VALUE * | argv, | ||
VALUE | klass | ||
) |
Definition at line 900 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE Message_encode | ( | VALUE | klass, |
VALUE | msg_rb | ||
) |
Definition at line 1442 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE Message_encode_json | ( | int | argc, |
VALUE * | argv, | ||
VALUE | klass | ||
) |
Definition at line 1480 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 792 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1416 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 800 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1408 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 761 of file ruby/ext/google/protobuf_c/encode_decode.c.
const upb_pbdecodermethod* new_fillmsg_decodermethod | ( | Descriptor * | desc, |
const void * | owner | ||
) |
Definition at line 783 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 414 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 109 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 143 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 124 of file ruby/ext/google/protobuf_c/encode_decode.c.
VALUE noleak_rb_str_cat | ( | VALUE | rb_str, |
const char * | str, | ||
long | len | ||
) |
Definition at line 37 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 468 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 455 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 481 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 488 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1060 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1008 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1159 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1243 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1115 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 1271 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 970 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 992 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 202 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 838 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 844 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 368 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 168 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 221 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 256 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 248 of file ruby/ext/google/protobuf_c/encode_decode.c.
void stringsink_init | ( | stringsink * | sink | ) |
Definition at line 81 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 52 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 58 of file ruby/ext/google/protobuf_c/encode_decode.c.
void stringsink_uninit | ( | stringsink * | sink | ) |
Definition at line 93 of file ruby/ext/google/protobuf_c/encode_decode.c.
Definition at line 285 of file ruby/ext/google/protobuf_c/encode_decode.c.
|
static |
Definition at line 699 of file ruby/ext/google/protobuf_c/encode_decode.c.
rb_data_type_t MapParseFrame_type |
Definition at line 347 of file ruby/ext/google/protobuf_c/encode_decode.c.