code: public static Class<? extends Channel> getClientChannelClass(IOMode mode) {
      switch (mode) {
        case NIO:
          return NioSocketChannel.class;
        case EPOLL:
          return EpollSocketChannel.class;
        default:
          throw new IllegalArgumentException("Unknown io mode: " + mode);
      }
    }
docs: Returns the correct (client) SocketChannel class based on IOMode.