equal
deleted
inserted
replaced
354 public boolean translateAndSetReadyOps(int ops, SelectionKeyImpl sk) { |
354 public boolean translateAndSetReadyOps(int ops, SelectionKeyImpl sk) { |
355 return translateReadyOps(ops, 0, sk); |
355 return translateReadyOps(ops, 0, sk); |
356 } |
356 } |
357 |
357 |
358 @Override |
358 @Override |
359 public void translateAndSetInterestOps(int ops, SelectionKeyImpl sk) { |
359 public int translateInterestOps(int ops) { |
360 int newOps = 0; |
360 int newOps = 0; |
361 if ((ops & SelectionKey.OP_READ) != 0) |
361 if ((ops & SelectionKey.OP_READ) != 0) |
362 newOps |= Net.POLLIN; |
362 newOps |= Net.POLLIN; |
363 if ((ops & SelectionKey.OP_WRITE) != 0) |
363 if ((ops & SelectionKey.OP_WRITE) != 0) |
364 newOps |= Net.POLLOUT; |
364 newOps |= Net.POLLOUT; |
365 sk.selector.putEventOps(sk, newOps); |
365 return newOps; |
366 } |
366 } |
367 |
367 |
368 @Override |
368 @Override |
369 public void kill() throws IOException { |
369 public void kill() throws IOException { |
370 synchronized (stateLock) { |
370 synchronized (stateLock) { |