Searched refs:pb_field_t (Results 1 - 18 of 18) sorted by relevance

/external/nanopb-c/
H A Dpb_encode.h67 bool pb_encode(pb_ostream_t *stream, const pb_field_t fields[], const void *src_struct);
72 bool pb_encode_delimited(pb_ostream_t *stream, const pb_field_t fields[], const void *src_struct);
76 bool pb_get_encoded_size(size_t *size, const pb_field_t fields[], const void *src_struct);
118 bool pb_encode_tag_for_field(pb_ostream_t *stream, const pb_field_t *field);
144 * You need to pass the pb_field_t array and pointer to struct, just like
148 bool pb_encode_submessage(pb_ostream_t *stream, const pb_field_t fields[], const void *src_struct);
H A Dpb_decode.h68 bool pb_decode(pb_istream_t *stream, const pb_field_t fields[], void *dest_struct);
80 bool pb_decode_noinit(pb_istream_t *stream, const pb_field_t fields[], void *dest_struct);
86 bool pb_decode_delimited(pb_istream_t *stream, const pb_field_t fields[], void *dest_struct);
93 void pb_release(const pb_field_t fields[], void *dest_struct);
H A Dpb_encode.c22 typedef bool (*pb_encoder_t)(pb_ostream_t *stream, const pb_field_t *field, const void *src) checkreturn;
25 static bool checkreturn encode_array(pb_ostream_t *stream, const pb_field_t *field, const void *pData, size_t count, pb_encoder_t func);
26 static bool checkreturn encode_field(pb_ostream_t *stream, const pb_field_t *field, const void *pData);
28 static bool checkreturn encode_extension_field(pb_ostream_t *stream, const pb_field_t *field, const void *pData);
29 static bool checkreturn pb_enc_varint(pb_ostream_t *stream, const pb_field_t *field, const void *src);
30 static bool checkreturn pb_enc_uvarint(pb_ostream_t *stream, const pb_field_t *field, const void *src);
31 static bool checkreturn pb_enc_svarint(pb_ostream_t *stream, const pb_field_t *field, const void *src);
32 static bool checkreturn pb_enc_fixed32(pb_ostream_t *stream, const pb_field_t *field, const void *src);
33 static bool checkreturn pb_enc_fixed64(pb_ostream_t *stream, const pb_field_t *field, const void *src);
34 static bool checkreturn pb_enc_bytes(pb_ostream_t *stream, const pb_field_t *fiel
[all...]
H A Dpb_decode.c23 /* Iterator for pb_field_t list */
25 const pb_field_t *start; /* Start of the pb_field_t array */
26 const pb_field_t *pos; /* Current position of the iterator */
34 typedef bool (*pb_decoder_t)(pb_istream_t *stream, const pb_field_t *field, void *dest) checkreturn;
39 static void pb_field_init(pb_field_iterator_t *iter, const pb_field_t *fields, void *dest_struct);
48 static void pb_message_set_to_defaults(const pb_field_t fields[], void *dest_struct);
49 static bool checkreturn pb_dec_varint(pb_istream_t *stream, const pb_field_t *field, void *dest);
50 static bool checkreturn pb_dec_uvarint(pb_istream_t *stream, const pb_field_t *field, void *dest);
51 static bool checkreturn pb_dec_svarint(pb_istream_t *stream, const pb_field_t *fiel
[all...]
H A Dpb.h209 typedef struct _pb_field_t pb_field_t; typedef in typeref:struct:_pb_field_t
278 bool (*decode)(pb_istream_t *stream, const pb_field_t *field, void *arg);
279 bool (*encode)(pb_ostream_t *stream, const pb_field_t *field, const void *arg);
284 bool (*decode)(pb_istream_t *stream, const pb_field_t *field, void **arg);
285 bool (*encode)(pb_ostream_t *stream, const pb_field_t *field, void * const *arg);
361 /* These macros are used to declare pb_field_t's in the constant array. */
/external/nanopb-c/examples/using_union_messages/
H A Ddecode.c17 const pb_field_t* decode_unionmessage_type(pb_istream_t *stream)
27 const pb_field_t *field;
45 bool decode_unionmessage_contents(pb_istream_t *stream, const pb_field_t fields[], void *dest_struct)
64 const pb_field_t *type = decode_unionmessage_type(&stream);
H A Dencode.c13 * the top-level pb_field_t array manually, in order to encode a correct
17 bool encode_unionmessage(pb_ostream_t *stream, const pb_field_t messagetype[], const void *message)
19 const pb_field_t *field;
/external/nanopb-c/tests/callbacks/
H A Dencode_callbacks.c9 bool encode_string(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
19 bool encode_int32(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
27 bool encode_fixed32(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
37 bool encode_fixed64(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
47 bool encode_repeatedstring(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
H A Ddecode_callbacks.c10 bool print_string(pb_istream_t *stream, const pb_field_t *field, void **arg)
28 bool print_int32(pb_istream_t *stream, const pb_field_t *field, void **arg)
38 bool print_fixed32(pb_istream_t *stream, const pb_field_t *field, void **arg)
48 bool print_fixed64(pb_istream_t *stream, const pb_field_t *field, void **arg)
/external/nanopb-c/tests/alltypes_callback/
H A Ddecode_alltypes_callback.c18 static bool read_varint(pb_istream_t *stream, const pb_field_t *field, void **arg)
28 static bool read_svarint(pb_istream_t *stream, const pb_field_t *field, void **arg)
38 static bool read_fixed32(pb_istream_t *stream, const pb_field_t *field, void **arg)
48 static bool read_fixed64(pb_istream_t *stream, const pb_field_t *field, void **arg)
58 static bool read_string(pb_istream_t *stream, const pb_field_t *field, void **arg)
70 static bool read_submsg(pb_istream_t *stream, const pb_field_t *field, void **arg)
81 static bool read_emptymsg(pb_istream_t *stream, const pb_field_t *field, void **arg)
87 static bool read_repeated_varint(pb_istream_t *stream, const pb_field_t *field, void **arg)
98 static bool read_repeated_svarint(pb_istream_t *stream, const pb_field_t *field, void **arg)
109 static bool read_repeated_fixed32(pb_istream_t *stream, const pb_field_t *fiel
[all...]
H A Dencode_alltypes_callback.c13 static bool write_varint(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
19 static bool write_svarint(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
25 static bool write_fixed32(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
31 static bool write_fixed64(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
37 static bool write_string(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
43 static bool write_submsg(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
50 static bool write_emptymsg(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
57 static bool write_repeated_varint(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
71 static bool write_repeated_svarint(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
85 static bool write_repeated_fixed32(pb_ostream_t *stream, const pb_field_t *fiel
[all...]
/external/nanopb-c/tests/decode_unittests/
H A Ddecode_unittests.c22 bool callback_check(pb_istream_t *stream, const pb_field_t *field, void **arg)
111 pb_field_t f = {1, PB_LTYPE_VARINT, 0, 0, 4, 0, 0};
124 pb_field_t f = {1, PB_LTYPE_SVARINT, 0, 0, 4, 0, 0};
136 pb_field_t f = {1, PB_LTYPE_SVARINT, 0, 0, 8, 0, 0};
148 pb_field_t f = {1, PB_LTYPE_FIXED32, 0, 0, 4, 0, 0};
160 pb_field_t f = {1, PB_LTYPE_FIXED64, 0, 0, 8, 0, 0};
172 pb_field_t f = {1, PB_LTYPE_BYTES, 0, 0, sizeof(d), 0, 0};
192 pb_field_t f = {1, PB_LTYPE_STRING, 0, 0, 5, 0, 0};
/external/nanopb-c/tests/backwards_compatibility/
H A Dalltypes_legacy.h157 extern const pb_field_t SubMessage_fields[4];
158 extern const pb_field_t AllTypes_fields[53];
160 /* Check that field information fits in pb_field_t */
H A Dalltypes_legacy.c31 const pb_field_t SubMessage_fields[4] = {
38 const pb_field_t AllTypes_fields[53] = {
/external/nanopb-c/examples/network_server/
H A Dclient.c26 bool printfile_callback(pb_istream_t *stream, const pb_field_t *field, void **arg)
H A Dserver.c26 bool listdir_callback(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
/external/nanopb-c/tests/encode_unittests/
H A Dencode_unittests.c20 bool fieldcallback(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
28 bool crazyfieldcallback(pb_ostream_t *stream, const pb_field_t *field, void * const *arg)
99 pb_field_t field = {10, PB_LTYPE_SVARINT};
132 pb_field_t field = {1, PB_LTYPE_VARINT, 0, 0, sizeof(value)};
/external/nanopb-c/generator/
H A Dnanopb_generator.py335 def pb_field_t(self, prev_field_name): member in class:Field
336 '''Return the pb_field_t initializer to use in the constant array.
362 '''Determine if this field needs 16bit or 32bit pb_field_t structure to compile properly.
487 result += ('static const pb_field_t %s_field = \n %s;\n\n' %
488 (self.fullname, self.pb_field_t(None)))
565 result = 'extern const pb_field_t %s_fields[%d];' % (self.name, len(self.fields) + 1)
569 result = 'const pb_field_t %s_fields[%d] = {\n' % (self.name, len(self.fields) + 1)
573 result += field.pb_field_t(prev)
831 yield '\n/* Check that field information fits in pb_field_t */\n'

Completed in 96 milliseconds