com.twistedmatrix.spread.pb
Class Connection
java.lang.Object
|
+--com.twistedmatrix.spread.pb.Connection
- public class Connection
- extends java.lang.Object
Various methods for connecting to a remote PB servers.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ROOT
public static final ByteString ROOT
USERNAME
public static final ByteString USERNAME
RESPOND
public static final ByteString RESPOND
ATTACH
public static final ByteString ATTACH
Connection
public Connection()
getObjectAt
public static RemoteReference getObjectAt(StreamPair sp)
- Get the remote object at the root of server.
connect
public static RemoteReference connect(StreamPair sp,
ByteString username,
ByteString password,
ByteString service,
ByteString perspective)
throws RemoteReference.RemoteError,
java.io.IOException
- Log in to a perspective.
- Parameters:
sp
- an open connection to a remote server.username
- the name you will be identified as to the authorizer.password
- the password for this username.service
- the service to request.perspective
- the name of the perspective to request.
connect
public static RemoteReference connect(StreamPair sp,
ByteString username,
ByteString password,
ByteString service)
throws RemoteReference.RemoteError,
java.io.IOException
- Log in to a perspective whose name is the same as the username.
- Parameters:
sp
- an open connection to a remote server.username
- the name you will be identified as to the authorizer.password
- the password for this username.service
- the service to request.
challengeResponse
public static ByteString challengeResponse(ByteString challenge,
ByteString password)
- Make a response to a challenge.