Class IoSessionEventQueue
java.lang.Object
org.apache.mina.proxy.event.IoSessionEventQueue
IoSessionEventQueue.java - Queue that contains filtered session events
while handshake isn't done.
- Since:
- MINA 2.0.0-M3
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final org.slf4j.Loggerprivate ProxyIoSessionThe proxy session object.private Queue<IoSessionEvent> Queue of session events which occurred before the proxy handshake had completed. -
Constructor Summary
ConstructorsConstructorDescriptionIoSessionEventQueue(ProxyIoSession proxyIoSession) Creates a new proxyIoSession instance -
Method Summary
Modifier and TypeMethodDescriptionprivate voidDiscard all events from the queue.voidEvent is enqueued only if necessary : - socks proxies do not need the reconnection feature so events are always forwarded for these.private voidEnqueue an event to be delivered once handshaking is complete.voidSend any session event which were queued while waiting for handshaking to complete.
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
proxyIoSession
The proxy session object. -
sessionEventsQueue
Queue of session events which occurred before the proxy handshake had completed.
-
-
Constructor Details
-
IoSessionEventQueue
Creates a new proxyIoSession instance- Parameters:
proxyIoSession- The proxy session instance
-
-
Method Details
-
discardSessionQueueEvents
private void discardSessionQueueEvents()Discard all events from the queue. -
enqueueEventIfNecessary
Event is enqueued only if necessary : - socks proxies do not need the reconnection feature so events are always forwarded for these. - http proxies events will be enqueued while handshake has not been completed or until connection was closed. If connection was prematurely closed previous events are discarded and only the session closed is delivered.- Parameters:
evt- the event to enqueue
-
flushPendingSessionEvents
-
enqueueSessionEvent
Enqueue an event to be delivered once handshaking is complete.- Parameters:
evt- the session event to enqueue
-