public abstract class TransportManager extends Object
| Constructor and Description |
|---|
TransportManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
changeRecvCipher(BlockCipher bc,
MAC mac) |
void |
changeSendCipher(BlockCipher bc,
MAC mac) |
void |
close(Socket sock,
Throwable cause,
boolean useDisconnectPacket) |
void |
close(Throwable cause) |
abstract void |
close(Throwable cause,
boolean useDisconnectPacket) |
void |
forceKeyExchange(CryptoWishList cwl,
DHGexParameters dhgex,
DSAPrivateKey dsa,
RSAPrivateKey rsa) |
ConnectionInfo |
getConnectionInfo(int kexNumber) |
int |
getPacketOverheadEstimate() |
Throwable |
getReasonClosedCause() |
byte[] |
getSessionIdentifier() |
protected void |
init(TransportConnection tc,
KexManager km) |
void |
kexFinished() |
void |
receiveLoop() |
void |
registerMessageHandler(MessageHandler mh,
int low,
int high) |
void |
removeMessageHandler(MessageHandler mh,
int low,
int high) |
void |
sendAsynchronousMessage(byte[] msg) |
void |
sendAsynchronousMessage(byte[] msg,
Runnable run) |
void |
sendKexMessage(byte[] msg) |
void |
sendMessage(byte[] msg)
Send a message but ensure that all queued messages are being sent first.
|
void |
sendMessageImmediate(byte[] msg)
Send message, ignore queued async messages that have not been delivered yet.
|
void |
setConnectionMonitors(List<ConnectionMonitor> monitors) |
protected void |
startReceiver() |
protected void init(TransportConnection tc, KexManager km)
public int getPacketOverheadEstimate()
public ConnectionInfo getConnectionInfo(int kexNumber) throws IOException
IOExceptionpublic Throwable getReasonClosedCause()
public byte[] getSessionIdentifier()
public void close(Throwable cause)
public abstract void close(Throwable cause, boolean useDisconnectPacket)
protected void startReceiver()
throws IOException
IOExceptionpublic void registerMessageHandler(MessageHandler mh, int low, int high)
public void removeMessageHandler(MessageHandler mh, int low, int high)
public void sendKexMessage(byte[] msg)
throws IOException
IOExceptionpublic void kexFinished()
throws IOException
IOExceptionpublic void forceKeyExchange(CryptoWishList cwl, DHGexParameters dhgex, DSAPrivateKey dsa, RSAPrivateKey rsa) throws IOException
cwl - dhgex - dsa - may be null if this is a client connectionrsa - may be null if this is a client connectionIOExceptionpublic void changeRecvCipher(BlockCipher bc, MAC mac)
public void changeSendCipher(BlockCipher bc, MAC mac)
public void sendAsynchronousMessage(byte[] msg)
throws IOException
IOExceptionpublic void sendAsynchronousMessage(byte[] msg,
Runnable run)
throws IOException
IOExceptionpublic void setConnectionMonitors(List<ConnectionMonitor> monitors)
public void sendMessage(byte[] msg)
throws IOException
msg - IOExceptionpublic void sendMessageImmediate(byte[] msg)
throws IOException
msg - IOExceptionpublic void receiveLoop()
throws IOException
IOExceptionCopyright © 2014. All Rights Reserved.