def create_basic_xml_info(readname, fname):
 to_print = ['    <trace>\n']
 to_print.append('        <trace_name>')
 to_print.append(readname)
 to_print.append('</trace_name>\n')
 info = None
 if config['xml_info']:
  if (fname in config['xml_info']):
   info = config['xml_info'][fname]
  else:
   try:
    info = config['xml_info'][fake_sff_name]
   except KeyError:
    pass
 if info:
  for key in info:
   to_print.append((((((('        <' + key) + '>') + info[key]) + '</') + key) + '>\n'))
 return ''.join(to_print)

def create_basic_xml_info ( readname , fname ) : to_print = [ '    <trace>\n' ] to_print . append ( '        <trace_name>' ) to_print . append ( readname ) to_print . append ( '</trace_name>\n' ) info = None if config [ 'xml_info' ] : if ( fname in config [ 'xml_info' ] ) : info = config [ 'xml_info' ] [ fname ] else : try : info = config [ 'xml_info' ] [ fake_sff_name ] except KeyError : pass if info : for key in info : to_print . append ( ( ( ( ( ( ( '        <' + key ) + '>' ) + info [ key ] ) + '</' ) + key ) + '>\n' ) ) return '' . join ( to_print )
formats a number of read specific infos into xml format .