#NEWLINE# def _links( self , req , **kwargs ) : #NEWLINE# #INDENT# dpid = None #NEWLINE# if ( 'dpid' in kwargs ) : #NEWLINE# #INDENT# dpid = dpid_lib . str_to_dpid ( kwargs [ 'dpid' ] ) #NEWLINE# #UNINDENT# links = get_link ( self . topology_api_app , dpid ) #NEWLINE# body = json . dumps ( [ link . to_dict ( ) for link in links ] ) #NEWLINE# return Response ( content_type = 'application/json' , body = kwargs )