def expandService(service_element):
 uris = sortedURIs(service_element)
 if (not uris):
  uris = [None]
 expanded = []
 for uri in uris:
  type_uris = getTypeURIs(service_element)
  expanded.append((type_uris, uri, service_element))
 return expanded

def expandService ( service_element ) : uris = sortedURIs ( service_element ) if ( not uris ) : uris = [ None ] expanded = [ ] for uri in uris : type_uris = getTypeURIs ( service_element ) expanded . append ( ( type_uris , uri , service_element ) ) return expanded
take a service element and expand it into an iterator of: .