#NEWLINE# def buildProtocol( self , addr ) : #NEWLINE# #INDENT# "Create a protocol to handle an established connection.\n\n        Create a new controller object and bind it with the created\n        protocol object: the protocol object is set as a weak\n        reference in attribute 'protocol' of the created controller\n        object.\n\n        Args:\n            addr: The address of the newly-established connection, as\n                a twisted.internet.interfaces.IAddress object.\n\n        Returns:\n            An OpenflowControllerStub object.\n        " #NEWLINE# p = ofprotoops . OpenflowProtocolOperationsFactory . buildProtocol ( self , addr ) #NEWLINE# c = self . _controller ( ) #NEWLINE# p . controller = c #NEWLINE# c . protocol = weakref . ref ( self ) #NEWLINE# return p