Package beepy :: Package transports :: Module base :: Class SelectReactor
[show private | hide private]
[frames | no frames]

Class SelectReactor


A reactor manages the main looping part of a client or server
Method Summary
  __init__(self)
  connectTCP(self, host, port, factory)
Initiate a connection to a remote host
  crash(self)
Hard exit
  iterate(self)
Run a single cycle of the main processing loop
  listenTCP(self, port, factory, interface)
Add a listening factory on a given port.
  removeFactory(self, factory)
  run(self)
Run the main loop continuously
  stop(self)
Interrupt the main loop and shut down

Method Details

connectTCP(self, host, port, factory)

Initiate a connection to a remote host
Parameters:
host - remote host to connect to
           (type=string)
port - port number to connect to
           (type=integer)
factory - the Factory to use to manage the connection
           (type=Factory object)

crash(self)

Hard exit

iterate(self)

Run a single cycle of the main processing loop

listenTCP(self, port, factory, interface='')

Add a listening factory on a given port. If no specific interface is provided, listen on all interfaces.
Parameters:
port - The port number to listen on
           (type=integer)
factory - the type of Factory to use for connections received on the port
           (type=a Factory class)
interface - A specific interface to listen on
           (type=string)

run(self)

Run the main loop continuously

stop(self)

Interrupt the main loop and shut down

Generated by Epydoc 2.0 on Thu Sep 30 14:39:25 2004 http://epydoc.sf.net