#NEWLINE# def send_port_stats( self ) : #NEWLINE# #INDENT# ' Get port stats.' #NEWLINE# ofp = self . dp . ofproto #NEWLINE# parser = self . dp . ofproto_parser #NEWLINE# flags = 0 #NEWLINE# if ( ofp . OFP_VERSION == ofproto_v1_0 . OFP_VERSION ) : #NEWLINE# #INDENT# port = ofp . OFPP_NONE #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# port = ofp . OFPP_ANY #NEWLINE# #UNINDENT# req = parser . OFPPortStatsRequest ( self . dp , flags , port ) #NEWLINE# return self . send_msg ( req )