code: def _handle_component(sourcekey, comp_dict):
          
          if comp_dict.comp_key is None:
              fullkey = sourcekey
          else:
              fullkey = "%s_%s" % (sourcekey, comp_dict.comp_key)
          srcdict = make_sources(fullkey, comp_dict)
          if comp_dict.model_type == 'IsoSource':
              print("Writing xml for %s to %s: %s %s" % (fullkey,
                                                         comp_dict.srcmdl_name,
                                                         comp_dict.model_type,
                                                         comp_dict.Spectral_Filename))
          elif comp_dict.model_type == 'MapCubeSource':
              print("Writing xml for %s to %s: %s %s" % (fullkey,
                                                         comp_dict.srcmdl_name,
                                                         comp_dict.model_type,
                                                         comp_dict.Spatial_Filename))
          SrcmapsDiffuse_SG._write_xml(comp_dict.srcmdl_name, srcdict.values())
docs: Make the source objects and write the xml for a component