EmbeddedProto  2.0.0
EmbeddedProto is a C++ Protocol Buffer implementation specifically suitable for microcontrollers.
Public Member Functions | Static Public Attributes | List of all members
support.Field.FieldBasic Class Reference
Inheritance diagram for support.Field.FieldBasic:
Inheritance graph
[legend]
Collaboration diagram for support.Field.FieldBasic:
Collaboration graph
[legend]

Public Member Functions

def __init__ (self, proto_descriptor, parent_msg, oneof=None)
 
def get_wire_type_str (self)
 
def get_type (self)
 
def get_short_type (self)
 
def get_default_value (self)
 
def render_get_set (self, jinja_env)
 
def render_serialize (self, jinja_env)
 
def render_deserialize (self, jinja_env)
 
- Public Member Functions inherited from support.Field.Field
def __init__ (self, proto_descriptor, parent_msg, template_filename, oneof=None)
 
def get_name (self)
 
def get_variable_name (self)
 
def get_variable_id_name (self)
 
def get_template_parameters (self)
 
def match_field_with_definitions (self, all_types_definitions)
 
def register_template_parameters (self)
 
def oneof_allocation_required (self)
 
def get_oneof_name (self)
 
def get_which_oneof (self)
 
def get_reduced_scope (self)
 
def render (self, filename, jinja_environment)
 

Static Public Attributes

dictionary type_to_default_value
 
dictionary type_to_cpp_type
 
dictionary type_to_wire_type
 

Additional Inherited Members

- Static Public Member Functions inherited from support.Field.Field
def factory (proto_descriptor, parent_msg, oneof=None, already_nested=False)
 
- Public Attributes inherited from support.Field.Field
 descriptor
 
 parent
 
 oneof
 
 name
 
 variable_name
 
 variable_id_name
 
 variable_id
 
 template_file
 
 of_type_enum
 

Constructor & Destructor Documentation

◆ __init__()

def support.Field.FieldBasic.__init__ (   self,
  proto_descriptor,
  parent_msg,
  oneof = None 
)

Member Function Documentation

◆ get_default_value()

def support.Field.FieldBasic.get_default_value (   self)

Reimplemented from support.Field.Field.

◆ get_short_type()

def support.Field.FieldBasic.get_short_type (   self)

Reimplemented from support.Field.Field.

◆ get_type()

def support.Field.FieldBasic.get_type (   self)

Reimplemented from support.Field.Field.

◆ get_wire_type_str()

def support.Field.FieldBasic.get_wire_type_str (   self)

Reimplemented from support.Field.Field.

◆ render_deserialize()

def support.Field.FieldBasic.render_deserialize (   self,
  jinja_env 
)

◆ render_get_set()

def support.Field.FieldBasic.render_get_set (   self,
  jinja_env 
)

◆ render_serialize()

def support.Field.FieldBasic.render_serialize (   self,
  jinja_env 
)

Member Data Documentation

◆ type_to_cpp_type

dictionary support.Field.FieldBasic.type_to_cpp_type
static
Initial value:
= {FieldDescriptorProto.TYPE_DOUBLE: "EmbeddedProto::doublefixed",
FieldDescriptorProto.TYPE_FLOAT: "EmbeddedProto::floatfixed",
FieldDescriptorProto.TYPE_INT64: "EmbeddedProto::int64",
FieldDescriptorProto.TYPE_UINT64: "EmbeddedProto::uint64",
FieldDescriptorProto.TYPE_INT32: "EmbeddedProto::int32",
FieldDescriptorProto.TYPE_FIXED64: "EmbeddedProto::fixed64",
FieldDescriptorProto.TYPE_FIXED32: "EmbeddedProto::fixed32",
FieldDescriptorProto.TYPE_BOOL: "EmbeddedProto::boolean",
FieldDescriptorProto.TYPE_UINT32: "EmbeddedProto::uint32",
FieldDescriptorProto.TYPE_SFIXED32: "EmbeddedProto::sfixed32",
FieldDescriptorProto.TYPE_SFIXED64: "EmbeddedProto::sfixed64",
FieldDescriptorProto.TYPE_SINT32: "EmbeddedProto::sint32",
FieldDescriptorProto.TYPE_SINT64: "EmbeddedProto::sint64"}

◆ type_to_default_value

dictionary support.Field.FieldBasic.type_to_default_value
static
Initial value:
= {FieldDescriptorProto.TYPE_DOUBLE: "0.0",
FieldDescriptorProto.TYPE_FLOAT: "0.0",
FieldDescriptorProto.TYPE_INT64: "0",
FieldDescriptorProto.TYPE_UINT64: "0U",
FieldDescriptorProto.TYPE_INT32: "0",
FieldDescriptorProto.TYPE_FIXED64: "0U",
FieldDescriptorProto.TYPE_FIXED32: "0U",
FieldDescriptorProto.TYPE_BOOL: "false",
FieldDescriptorProto.TYPE_UINT32: "0U",
FieldDescriptorProto.TYPE_SFIXED32: "0",
FieldDescriptorProto.TYPE_SFIXED64: "0",
FieldDescriptorProto.TYPE_SINT32: "0",
FieldDescriptorProto.TYPE_SINT64: "0"}

◆ type_to_wire_type

dictionary support.Field.FieldBasic.type_to_wire_type
static
Initial value:
= {FieldDescriptorProto.TYPE_INT32: "VARINT",
FieldDescriptorProto.TYPE_INT64: "VARINT",
FieldDescriptorProto.TYPE_UINT32: "VARINT",
FieldDescriptorProto.TYPE_UINT64: "VARINT",
FieldDescriptorProto.TYPE_SINT32: "VARINT",
FieldDescriptorProto.TYPE_SINT64: "VARINT",
FieldDescriptorProto.TYPE_BOOL: "VARINT",
FieldDescriptorProto.TYPE_FIXED64: "FIXED64",
FieldDescriptorProto.TYPE_SFIXED64: "FIXED64",
FieldDescriptorProto.TYPE_DOUBLE: "FIXED64",
FieldDescriptorProto.TYPE_FIXED32: "FIXED32",
FieldDescriptorProto.TYPE_FLOAT: "FIXED32",
FieldDescriptorProto.TYPE_SFIXED32: "FIXED32"}

The documentation for this class was generated from the following file: