< prev index next >
src/java.base/share/classes/sun/nio/ch/SelectorImpl.java
Print this page
rev 49271 : [mq]: selector-cleanup
*** 76,85 ****
--- 76,95 ----
if (!isOpen())
throw new ClosedSelectorException();
return publicSelectedKeys;
}
+ /**
+ * Returns the public view of the key sets
+ */
+ protected final Set<SelectionKey> nioKeys() {
+ return publicKeys;
+ }
+ protected final Set<SelectionKey> nioSelectedKeys() {
+ return publicSelectedKeys;
+ }
+
protected abstract int doSelect(long timeout) throws IOException;
private int lockAndDoSelect(long timeout) throws IOException {
synchronized (this) {
if (!isOpen())
*** 123,134 ****
}
}
protected abstract void implClose() throws IOException;
- public abstract void putEventOps(SelectionKeyImpl sk, int ops);
-
@Override
protected final SelectionKey register(AbstractSelectableChannel ch,
int ops,
Object attachment)
{
--- 133,142 ----
*** 164,169 ****
--- 172,182 ----
}
}
}
}
}
+
+ /**
+ * Invoked to change the key's interest set
+ */
+ public abstract void putEventOps(SelectionKeyImpl ski, int ops);
}
< prev index next >