Module pyinsim :: Class OutSim
[hide private]
[frames] | no frames]

Class OutSim

source code

OutReceiver --+
              |
             OutSim

Motion Simulator Support.

Simple wrapper for OutReceiver, which handles an OutSim socket. See OutReceiver for more info.

Instance Methods [hide private]
 
__init__(self, timeout=10.0, name='default')
Initailise the OutSim object.
source code
    Inherited from OutReceiver
 
bind(self, evtType, callback)
Bind an event-handler.
source code
string
getName(self)
Get the name of the socket.
source code
number
getTimeout(self)
Get the timeout seconds.
source code
boolean
isBound(self, evtType, callback)
Get if an event-handler has been bound.
source code
boolean
isConnected(self)
Get if the OutReceiver is connected.
source code
 
onOutEvent(self, evtType, args)
Virtual method called when a Closed event is raised.
source code
 
raisePacketEvent(self, *packets)
Raise a packet-event as if it has been received by the OutReceiver.
source code
 
run(self)
Block the calling thread until the OutReceiver has closed.
source code
 
setName(self, name)
Set the name of the socket.
source code
 
setTimeout(self, timeout)
Set the timeout seconds.
source code
 
start(self, host='localhost', port=30000)
Start the OutReceiver.
source code
 
stop(self)
Stop the OutReceiver.
source code
 
unbind(self, evtType, callback)
Unbind an event-handler.
source code
Method Details [hide private]

__init__(self, timeout=10.0, name='default')
(Constructor)

source code 

Initailise the OutSim object.

Parameters:
  • timeout (number) - The number of seconds to wait before timing out.
  • name (string) - An optional name for the OutSim socket.
Overrides: OutReceiver.__init__