com.hazelcast.nio.tcp
Class WriteHandler

java.lang.Object
  extended by com.hazelcast.nio.tcp.AbstractSelectionHandler
      extended by com.hazelcast.nio.tcp.WriteHandler
All Implemented Interfaces:
MigratableHandler, SelectionHandler, Runnable

public final class WriteHandler
extends AbstractSelectionHandler
implements Runnable

The writing side of the TcpIpConnection.


Field Summary
 
Fields inherited from class com.hazelcast.nio.tcp.AbstractSelectionHandler
connection, connectionManager, ioSelector, logger, selector, socketChannel
 
Method Summary
 long getEventCount()
          Get number of events recorded by the current handler.
 SocketWriter getSocketWriter()
           
 void handle()
           
 void offer(SocketWritable packet)
           
 void run()
           
 void shutdown()
           
 
Methods inherited from class com.hazelcast.nio.tcp.AbstractSelectionHandler
getOwner, getSelectionKey, migrate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getSocketWriter

public SocketWriter getSocketWriter()

offer

public void offer(SocketWritable packet)

getEventCount

public long getEventCount()
Description copied from interface: MigratableHandler
Get number of events recorded by the current handler. It can be used to calculate whether this handler should be migrated to a different IOSelector

Specified by:
getEventCount in interface MigratableHandler
Returns:
total number of events recorded by this handler

handle

public void handle()
Specified by:
handle in interface SelectionHandler

run

public void run()
Specified by:
run in interface Runnable

shutdown

public void shutdown()


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.