#NEWLINE# def _get_metadata_id( self , flows , ip , mac ) : #NEWLINE# #INDENT# for flow in flows : #NEWLINE# #INDENT# if ( flow [ 'table' ] == str ( const . L3_PROACTIVE_LOOKUP_TABLE ) ) : #NEWLINE# #INDENT# if ( ( ( 'nw_dst=' + ip ) in flow [ 'match' ] ) and ( mac in flow [ 'actions' ] ) ) : #NEWLINE# #INDENT# m = re . search ( 'metadata=0x([0-9a-f]+)' , flow [ 'match' ] ) #NEWLINE# if m : #NEWLINE# #INDENT# return m . group ( 1 ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# #UNINDENT# return None