Package twisted :: Package spread :: Module pb :: Class IdentityConnector

[show private | hide private]
[frames | no frames]

## Class IdentityConnector

I support connecting to multiple Perspective Broker services that are in a service tree.

Method Summary
| ``__init__`(self, host, port, identityName, password)`
`twisted.internet.defer.Deferred` | ``requestLogin`(self)` Attempt to authenticate about the PB server, but don't request any services, yet.
`twisted.internet.defer.Deferred` | ``requestService`(self, serviceName, perspectiveName, client)` Request a perspective on the specified service.

Method Details

### __init__(self, host, port, identityName, password)
(Constructor)

  Parameters:
    `host` - The host to connect to or the PB server. If this is `"unix"`, then a UNIX socket will be used rather than a TCP socket.
    (type=`string`)
    `port` - The port to connect to for the PB server.
    (type=`integer`)
    `identityName` - The name of the identity to use to autheticate with the PB server.
    (type=`string`)
    `password` - The password to use to autheticate with the PB server.
    (type=`string`)

### requestLogin(self)

Attempt to authenticate about the PB server, but don't request any services, yet.

  Returns:
    `twisted.internet.defer.Deferred`

### requestService(self, serviceName, perspectiveName=None, client=None)

Request a perspective on the specified service. This will authenticate against the server as well if `requestLogin` hasn't already been called.

  Parameters:
    `serviceName` - The name of the service to obtain a perspective for.
    (type=`string`)
    `perspectiveName` - If specified, the name of the perspective to obtain. Otherwise, default to the name of the identity.
    (type=`string`)
    `client` - The client object to attach to the perspective.
  Returns:
    A deferred which will receive a callback with the perspective.
    (type=`twisted.internet.defer.Deferred`)

Generated by Epydoc 1.1 on Sat Feb 15 21:18:12 2003 | http://epydoc.sf.net