org.glassfish.grizzly.Connection.disableIOEvent()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(8.5k)|赞(0)|评价(0)|浏览(111)

本文整理了Java中org.glassfish.grizzly.Connection.disableIOEvent()方法的一些代码示例,展示了Connection.disableIOEvent()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Connection.disableIOEvent()方法的具体详情如下:
包路径:org.glassfish.grizzly.Connection
类名称:Connection
方法名:disableIOEvent

Connection.disableIOEvent介绍

暂无

代码示例

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-http-server-core

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-framework

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-core

private static void disableIOEvent(final Context context)
    throws IOException {
  final Connection connection = context.getConnection();
  final IOEvent ioEvent = context.getIoEvent();
  connection.disableIOEvent(ioEvent);
}

代码示例来源:origin: javaee/grizzly

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled)
    throws IOException {
  final boolean isReadOrWriteEvent = isReadWrite(ioEvent);
  final IOEventLifeCycleListener listener;
  if (isReadOrWriteEvent) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  } else {
    listener = null;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    threadPool.execute(
        new WorkerThreadRunnable(connection, ioEvent, listener));
  } else {
    run0(connection, ioEvent, listener);
  }
  return true;
}

代码示例来源:origin: org.mule.services/mule-service-http

@Override
public boolean executeIoEvent(final Connection connection, final IOEvent ioEvent, final boolean isIoEventEnabled)
  throws IOException {
 final boolean isReadOrWriteEvent = isReadWrite(ioEvent);
 final IOEventLifeCycleListener listener;
 if (isReadOrWriteEvent) {
  if (isIoEventEnabled) {
   connection.disableIOEvent(ioEvent);
  }
  listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
 } else {
  listener = null;
 }
 final Executor threadPool = getThreadPoolFor(connection, ioEvent);
 if (threadPool != null) {
  threadPool.execute(new WorkerThreadRunnable(connection, ioEvent, listener));
 } else {
  run0(connection, ioEvent, listener);
 }
 return true;
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled)
    throws IOException {
  final boolean isReadOrWriteEvent = isReadWrite(ioEvent);
  final IOEventLifeCycleListener listener;
  if (isReadOrWriteEvent) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  } else {
    listener = null;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    threadPool.execute(
        new WorkerThreadRunnable(connection, ioEvent, listener));
  } else {
    run0(connection, ioEvent, listener);
  }
  return true;
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled) throws IOException {
  final NIOConnection nioConnection = (NIOConnection) connection;
  IOEventLifeCycleListener listener = null;
  if (isReadWrite(ioEvent)) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    final SelectorRunner runner = nioConnection.getSelectorRunner();
    runner.postpone();
    threadPool.execute(runner);
    fireIOEvent(connection, ioEvent, listener, logger);
    return false;
  } else {
    fireIOEvent(connection, ioEvent, listener, logger);
    return true;
  }
}

代码示例来源:origin: javaee/grizzly

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled) throws IOException {
  final NIOConnection nioConnection = (NIOConnection) connection;
  IOEventLifeCycleListener listener = null;
  if (isReadWrite(ioEvent)) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    final SelectorRunner runner = nioConnection.getSelectorRunner();
    runner.postpone();
    threadPool.execute(runner);
    fireIOEvent(connection, ioEvent, listener, logger);
    return false;
  } else {
    fireIOEvent(connection, ioEvent, listener, logger);
    return true;
  }
}

代码示例来源:origin: javaee/grizzly

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled) throws IOException {
  final NIOConnection nioConnection = (NIOConnection) connection;
  IOEventLifeCycleListener listener = null;
  if (isReadWrite(ioEvent)) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    final SelectorRunner runner = nioConnection.getSelectorRunner();
    runner.postpone();
    threadPool.execute(runner);
    fireIOEvent(connection, ioEvent, listener, logger);
    return false;
  } else {
    fireIOEvent(connection, ioEvent, listener, logger);
    return true;
  }
}

代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-framework

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled) throws IOException {
  final NIOConnection nioConnection = (NIOConnection) connection;
  IOEventLifeCycleListener listener = null;
  if (isReadWrite(ioEvent)) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    final SelectorRunner runner = nioConnection.getSelectorRunner();
    runner.postpone();
    threadPool.execute(runner);
    fireIOEvent(connection, ioEvent, listener, logger);
    return false;
  } else {
    fireIOEvent(connection, ioEvent, listener, logger);
    return true;
  }
}

代码示例来源:origin: javaee/grizzly

@Override
public boolean executeIoEvent(final Connection connection,
    final IOEvent ioEvent, final boolean isIoEventEnabled) throws IOException {
  final NIOConnection nioConnection = (NIOConnection) connection;
  IOEventLifeCycleListener listener = null;
  if (isReadWrite(ioEvent)) {
    if (isIoEventEnabled) {
      connection.disableIOEvent(ioEvent);
    }
    
    listener = ENABLE_INTEREST_LIFECYCLE_LISTENER;
  }
  final Executor threadPool = getThreadPoolFor(connection, ioEvent);
  if (threadPool != null) {
    final SelectorRunner runner = nioConnection.getSelectorRunner();
    runner.postpone();
    threadPool.execute(runner);
    fireIOEvent(connection, ioEvent, listener, logger);
    return false;
  } else {
    fireIOEvent(connection, ioEvent, listener, logger);
    return true;
  }
}

相关文章