Interface ProxyLogicHandler
- All Known Implementing Classes:
AbstractHttpLogicHandler, AbstractProxyLogicHandler, AbstractSocksLogicHandler, HttpSmartProxyHandler, Socks4LogicHandler, Socks5LogicHandler
public interface ProxyLogicHandler
ProxyLogicHandler.java - Interface implemented by classes containing proxy type specific logic.
- Since:
- MINA 2.0.0-M3
-
Method Summary
Modifier and TypeMethodDescriptionvoiddoHandshake(IoFilter.NextFilter nextFilter) Called at each step of the handshake procedure.voidenqueueWriteRequest(IoFilter.NextFilter nextFilter, WriteRequest writeRequest) Enqueue a message to be written once handshaking is complete.booleanTests if handshake process is complete.voidmessageReceived(IoFilter.NextFilter nextFilter, IoBuffer buf) Handle incoming data during the handshake process.
-
Method Details
-
isHandshakeComplete
boolean isHandshakeComplete()Tests if handshake process is complete.- Returns:
trueif handshaking is complete and data can be sent through the proxy, false otherwise.
-
messageReceived
Handle incoming data during the handshake process. Should consume only the handshake data from the buffer, leaving any extra data in place.- Parameters:
nextFilter- the next filter in the filter chainbuf- the buffer holding the received data- Throws:
ProxyAuthException- if authentication fails
-
doHandshake
Called at each step of the handshake procedure.- Parameters:
nextFilter- the next filter in filter chain- Throws:
ProxyAuthException- if authentication fails
-
getProxyIoSession
ProxyIoSession getProxyIoSession()- Returns:
- the
ProxyIoSession.
-
enqueueWriteRequest
Enqueue a message to be written once handshaking is complete.- Parameters:
nextFilter- the next filter in filter chainwriteRequest- the data to be written
-