anon.client
Class SingleChannelDataChain
java.lang.Object
anon.client.AbstractDataChain
anon.client.SingleChannelDataChain
- All Implemented Interfaces:
- AnonChannel, java.lang.Runnable, java.util.Observer
public class SingleChannelDataChain
- extends AbstractDataChain
- Author:
- Stefan Lieske
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FLAG_FLOW_CONTROL
private static final short FLAG_FLOW_CONTROL
- See Also:
- Constant Field Values
CLOSE_CELL_CONNECTION_ERROR
private static final int CLOSE_CELL_CONNECTION_ERROR
- See Also:
- Constant Field Values
m_chainType
private int m_chainType
m_supportFlowControl
private boolean m_supportFlowControl
m_associatedChannel
private AbstractDataChannel m_associatedChannel
m_firstUpstreamPacket
private boolean m_firstUpstreamPacket
m_downstreamSendMeCount
private int m_downstreamSendMeCount
m_downstreamSendMeLimit
private int m_downstreamSendMeLimit
m_bEnhancedChannelEncryption
private boolean m_bEnhancedChannelEncryption
SingleChannelDataChain
public SingleChannelDataChain(IDataChannelCreator a_channelCreator,
DataChainErrorListener a_errorListener,
int a_chainType,
boolean a_supportFlowControl,
int upstreamSendMe,
int downstreamSendMe,
boolean a_enhancedChannelEncryption)
getOutputBlockSize
public int getOutputBlockSize()
- Description copied from interface:
AnonChannel
- Returns a value that indicates the current optimum size of data to write.. Because often
anon services transport the data splited into packets for optimum performance
it may be good to send data according to the packet size to avoid unneccessary overheads.
- Specified by:
getOutputBlockSize
in interface AnonChannel
- Specified by:
getOutputBlockSize
in class AbstractDataChain
- Returns:
- the current optimum size for output data. If 1 is returned the size does not matter.
createPacketPayload
public void createPacketPayload(DataChainSendOrderStructure a_order)
- Specified by:
createPacketPayload
in class AbstractDataChain
run
public void run()
- Specified by:
run
in interface java.lang.Runnable
- Specified by:
run
in class AbstractDataChain
orderPacket
protected void orderPacket(DataChainSendOrderStructure a_order)
- Specified by:
orderPacket
in class AbstractDataChain
outputStreamClosed
protected void outputStreamClosed()
throws java.io.IOException
- Specified by:
outputStreamClosed
in class AbstractDataChain
- Throws:
java.io.IOException
closeDataChain
protected void closeDataChain()
- Specified by:
closeDataChain
in class AbstractDataChain