def createAMQPListener(username, password, vhost, exchange_name, spec=None, channel=1, verbose=False):
 if (not spec):
  spec = txamqp.spec.load(os.path.normpath(os.path.join(os.path.dirname(__file__), 'amqp0-8.xml')))
 delegate = TwistedDelegate()
 factory = AMQPReconnectingFactory(username, password, delegate, vhost, spec, channel, exchange_name, verbose=verbose)
 return factory

def createAMQPListener ( username , password , vhost , exchange_name , spec = None , channel = 1 , verbose = False ) : if ( not spec ) : spec = txamqp . spec . load ( os . path . normpath ( os . path . join ( os . path . dirname ( __file__ ) , 'amqp0-8.xml' ) ) ) delegate = TwistedDelegate ( ) factory = AMQPReconnectingFactory ( username , password , delegate , vhost , spec , channel , exchange_name , verbose = verbose ) return factory
create an c{amqpreconnectingfactory} configured with the specified options .