public abstract class IOChannel
extends java.lang.Object
implements java.nio.channels.Channel
| Modifier and Type | Class and Description |
|---|---|
static class |
IOChannel.IOReadableByteChannel |
static class |
IOChannel.IOReadableWritableByteChannel |
static class |
IOChannel.IOWritableByteChannel |
| Modifier and Type | Field and Description |
|---|---|
private CallSite |
closeAdapter |
private IRubyObject |
io |
| Modifier | Constructor and Description |
|---|---|
protected |
IOChannel(IRubyObject io)
Creates a new OutputStream with the object provided.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected CallSite |
initReadSite() |
protected CallSite |
initWriteSite() |
boolean |
isOpen() |
protected int |
read(CallSite read,
java.nio.ByteBuffer dst) |
protected int |
write(CallSite write,
java.nio.ByteBuffer src) |
private final IRubyObject io
private final CallSite closeAdapter
protected IOChannel(IRubyObject io)
io - the ruby objectpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in interface java.nio.channels.Channeljava.io.IOExceptionpublic boolean isOpen()
isOpen in interface java.nio.channels.Channelprotected int read(CallSite read, java.nio.ByteBuffer dst) throws java.io.IOException
java.io.IOExceptionprotected int write(CallSite write, java.nio.ByteBuffer src) throws java.io.IOException
java.io.IOExceptionprotected CallSite initReadSite()
protected CallSite initWriteSite()