def resolve_uri(s, namespaces=cdao_namespaces, cdao_to_obo=True, xml_style=False):
 if (cdao_to_obo and s.startswith('cdao:')):
  return resolve_uri(('obo:%s' % cdao_elements[s[5:]]), namespaces, cdao_to_obo)
 for prefix in namespaces:
  if xml_style:
   s = s.replace((prefix + ':'), ('{%s}' % namespaces[prefix]))
  else:
   s = s.replace((prefix + ':'), namespaces[prefix])
 return s

def resolve_uri ( s , namespaces = cdao_namespaces , cdao_to_obo = True , xml_style = False ) : if ( cdao_to_obo and s . startswith ( 'cdao:' ) ) : return resolve_uri ( ( 'obo:%s' % cdao_elements [ s [ 5 : ] ] ) , namespaces , cdao_to_obo ) for prefix in namespaces : if xml_style : s = s . replace ( ( prefix + ':' ) , ( '{%s}' % namespaces [ prefix ] ) ) else : s = s . replace ( ( prefix + ':' ) , namespaces [ prefix ] ) return s
converts prefixed uris to full uris .