Package dtest :: Class SessionHandler
[show private | hide private]
[frames | no frames]

Type SessionHandler

object --+
         |
        SessionHandler

Known Subclasses:
LocalSessionHandler, SSHSessionHandler

Represents low-level DTest session handler.

A dtest session handler is responsible for giving a DTester the low level mean to have a pty-like access to the session and an eventual file manipulation capability Thus DTestSessionHandler may have several capabilities: The command run capability includes:
Method Summary
  __init__(self, runCommandCapable, fileTransferCapable)
Create a Default Session Handler with no capability.
  close(self)
Close the session.
  getFile(self, sourcePath, destinationPath)
  open(self, *args, **kwargs)
Open the session
  openIfNotOpened(self)
Open the session if it is not already opened.
  putFile(self, sourcePath, destinationPath)
  recv(self, size, buffer)
  recv_ready(self)
  send(self, string)
Send a string to the session
  sendall(self, string)
  updateEnviron(self, environ)
Update the environment
  __getLastReceive(self)
  __getLastSent(self)
  __isnotoverloaded(self, method)
  __setLastReceive(self, string)
  __setLastSent(self, string)
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __repr__(x)
x.__repr__() <==> repr(x)
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)

Property Summary
  lastReceive
  lastSent

Class Variable Summary
Formatter fmt = <logging.Formatter instance at 0xb7c2496c>
Logger logger = <logging.Logger instance at 0xb7c24cac>
StreamHandler sh = <logging.StreamHandler instance at 0xb7c24c4c>
classobj SessionFailureException = dtest.dtester.SessionFailureException
classobj UnableToFileTransferException = dtest.dtester.UnableToFileTransferException
classobj UnableToRunCommandException = dtest.dtester.UnableToRunCommandException
classobj UnableToUpdateEnvironException = dtest.dtester.UnableToUpdateEnvironException

Method Details

__init__(self, runCommandCapable=False, fileTransferCapable=False)
(Constructor)

Create a Default Session Handler with no capability.
Overrides:
__builtin__.object.__init__

close(self)

Close the session.

open(self, *args, **kwargs)

Open the session

openIfNotOpened(self)

Open the session if it is not already opened.

send(self, string)

Send a string to the session

updateEnviron(self, environ)

Update the environment

Property Details

lastReceive

Get Method:
__getLastReceive(self)
Set Method:
__setLastReceive(self, string)

lastSent

Get Method:
__getLastSent(self)
Set Method:
__setLastSent(self, string)

Class Variable Details

fmt

Type:
Formatter
Value:
<logging.Formatter instance at 0xb7c2496c>                             

logger

Type:
Logger
Value:
<logging.Logger instance at 0xb7c24cac>                                

sh

Type:
StreamHandler
Value:
<logging.StreamHandler instance at 0xb7c24c4c>                         

Generated by Epydoc 2.1 on Wed Jun 13 18:12:48 2007 http://epydoc.sf.net