Package org.jppf.nio

Interface StatelessNioServer.KeysetHandler<C extends AbstractNioContext>

Type Parameters:
C - the type of context associated with the channels.
Enclosing class:
StatelessNioServer<C extends AbstractNioContext>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface protected static interface StatelessNioServer.KeysetHandler<C extends AbstractNioContext>
A fuctional interface wrapping an operation on a set of selected channels.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final org.slf4j.Logger
    Logger for this class.
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    handle(StatelessNioServer<C> server, Set<SelectionKey> selectedKeys)
    Handle the operation on a set of channels.
    void
    Handle the operation on a single channel.
  • Field Details

    • log2

      static final org.slf4j.Logger log2
      Logger for this class.
  • Method Details

    • handle

      default void handle(StatelessNioServer<C> server, Set<SelectionKey> selectedKeys)
      Handle the operation on a set of channels.
      Parameters:
      server - the associated nio server.
      selectedKeys - the set of channels to handle.
    • handleKey

      void handleKey(StatelessNioServer<C> server, SelectionKey key) throws Exception
      Handle the operation on a single channel.
      Parameters:
      server - the associated nio server.
      key - the channel to handle.
      Throws:
      Exception - if any error occurs.