• Home
  • Raw
  • Download

Lines Matching refs:field_options

267     def __init__(self, struct_name, desc, field_options):  argument
281 if field_options.type == nanopb_pb2.FT_INLINE:
285 field_options.type = nanopb_pb2.FT_STATIC
286 field_options.fixed_length = True
289 if field_options.HasField("max_size"):
290 self.max_size = field_options.max_size
292 if desc.type == FieldD.TYPE_STRING and field_options.HasField("max_length"):
294 self.max_size = field_options.max_length + 1
296 if field_options.HasField("max_count"):
297 self.max_count = field_options.max_count
310 self.fixed_count = field_options.fixed_count
312 elif field_options.proto3:
330 if field_options.type == nanopb_pb2.FT_DEFAULT:
332 field_options.type = nanopb_pb2.FT_STATIC
334 field_options.type = nanopb_pb2.FT_CALLBACK
336 if field_options.type == nanopb_pb2.FT_STATIC and not can_be_static:
340 if field_options.fixed_count and self.max_count is None:
344 if field_options.type == nanopb_pb2.FT_STATIC:
346 elif field_options.type == nanopb_pb2.FT_POINTER:
348 elif field_options.type == nanopb_pb2.FT_CALLBACK:
351 raise NotImplementedError(field_options.type)
358 if isa and field_options.int_size != nanopb_pb2.IS_DEFAULT:
359 self.ctype = intsizes[field_options.int_size]
376 if field_options.fixed_length:
687 def __init__(self, struct_name, range_start, field_options): argument
722 def __init__(self, struct_name, desc, field_options): argument
725 Field.__init__(self, self.fullname + 'struct', desc, field_options)
899 field_options = get_nanopb_suboptions(f, message_options, self.name + f.name)
900 if field_options.type == nanopb_pb2.FT_IGNORE:
903 field = Field(self.name, f, field_options)
913 field_options = get_nanopb_suboptions(desc, message_options, self.name + 'extensions')
915 if field_options.type != nanopb_pb2.FT_IGNORE:
916 self.fields.append(ExtensionRange(self.name, range_start, field_options))
1128field_options = get_nanopb_suboptions(extension, self.file_options, names + extension.name)
1129 if field_options.type != nanopb_pb2.FT_IGNORE:
1130 self.extensions.append(ExtensionField(names, extension, field_options))