public class SelectorPool extends Object
cleanup()
for releasing selectors.Constructor and Description |
---|
SelectorPool() |
Modifier and Type | Method and Description |
---|---|
void |
cleanup()
Clean up a pool.
|
Selector |
get()
Get a selector from the pool (or create a new one).
|
Selector |
get(SelectorProvider provider)
Get a selector from the pool (or create a new one).
|
void |
put(Selector selector)
Put a selector back into the pool.
|
public Selector get() throws IOException
IOException
- if there's a problem opening a new selectorpublic Selector get(SelectorProvider provider) throws IOException
IOException
- if there's a problem opening a new selectorpublic void put(Selector selector)
selector
- the selector to put backpublic void cleanup()
Copyright © 2001-2015 JRuby. All Rights Reserved.