def __init__(self, partition, prefix='Rte', include=None, mode_switch=True, os_enable=True):
      self.partition=partition
      self.includes = [] #array of tuples, first element is the name of include header, second element is True if this is a sysinclude
      self.prefix=prefix
      self.com_component = None
      self.header_file_name = None
      self.data_elements = []
      self.extra_static_vars={}
      self.extra_public_functions={}
      self.extra_rte_start=C.sequence()
      self.mode_switch_enable=mode_switch
      self.os_enable = os_enable
      #self.com_access = {'receive': {}, 'send': {}}
      if include is not None:
         for elem in include:
            if isinstance(elem, str) or isinstance(elem, tuple):
               self.includes.append(elem)
            else:
               raise ValueError("include items must be of type str or tuple(str,boolean)")
      for component in partition.components:
         if isinstance(component.inner, autosar.bsw.com.ComComponent):
            if self.com_component is None:
               self.com_component = component
            else:
               raise RuntimeError("More than one Com component allowed in a partition")