def delete_rax_network(args):
 print ("--- Cleaning Cloud Networks matching '%s'" % args.match_re)
 for region in pyrax.identity.services.network.regions:
  cnw = pyrax.connect_to_cloud_networks(region=region)
  for network in cnw.list():
   if re.search(args.match_re, network.name):
    prompt_and_delete(network, ('Delete matching %s? [y/n]: ' % network), args.assumeyes)

def delete_rax_network ( args ) : print ( "--- Cleaning Cloud Networks matching '%s'" % args . match_re ) for region in pyrax . identity . services . network . regions : cnw = pyrax . connect_to_cloud_networks ( region = region ) for network in cnw . list ( ) : if re . search ( args . match_re , network . name ) : prompt_and_delete ( network , ( 'Delete matching %s? [y/n]: ' % network ) , args . assumeyes )
function for deleting cloud networks .