#NEWLINE# def set_data( self , vlan_id , param , waiters ) : #NEWLINE# #INDENT# vlan_routers = self . _get_vlan_router ( vlan_id ) #NEWLINE# if ( not vlan_routers ) : #NEWLINE# #INDENT# vlan_routers = [ self . _add_vlan_router ( vlan_id ) ] #NEWLINE# #UNINDENT# msgs = [ ] #NEWLINE# for vlan_router in vlan_routers : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# msg = vlan_router . set_data ( param ) #NEWLINE# msgs . append ( msg ) #NEWLINE# if ( msg [ REST_RESULT ] == REST_NG ) : #NEWLINE# #INDENT# self . _del_vlan_router ( vlan_router . vlan_id , waiters ) #NEWLINE# #UNINDENT# #UNINDENT# except ValueError as err_msg : #NEWLINE# #INDENT# self . _del_vlan_router ( vlan_router . vlan_id , waiters ) #NEWLINE# raise err_msg #NEWLINE# #UNINDENT# #UNINDENT# return { #NEWLINE# #INDENT# REST_SWITCHID : self . dpid_str , #NEWLINE# REST_COMMAND_RESULT : msgs , #NEWLINE# #UNINDENT# }