Package org.apache.cassandra.net
Class SharedDefaultFileRegion
- java.lang.Object
-
- io.netty.util.AbstractReferenceCounted
-
- io.netty.channel.DefaultFileRegion
-
- org.apache.cassandra.net.SharedDefaultFileRegion
-
- All Implemented Interfaces:
io.netty.channel.FileRegion
,io.netty.util.ReferenceCounted
public class SharedDefaultFileRegion extends io.netty.channel.DefaultFileRegion
Netty's DefaultFileRegion closes the underlying FileChannel as soon as the refCnt() for the region drops to zero, this is an implementation of the DefaultFileRegion that doesn't close the FileChannel. SeeAsyncChannelOutputPlus
for its usage.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SharedDefaultFileRegion.SharedFileChannel
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
deallocate()
static SharedDefaultFileRegion.SharedFileChannel
share(java.nio.channels.FileChannel fileChannel)
-
Methods inherited from class io.netty.channel.DefaultFileRegion
count, isOpen, open, position, retain, retain, touch, touch, transfered, transferred, transferTo
-
Methods inherited from class io.netty.util.AbstractReferenceCounted
refCnt, release, release, setRefCnt
-
-
-
-
Method Detail
-
deallocate
protected void deallocate()
- Overrides:
deallocate
in classio.netty.channel.DefaultFileRegion
-
share
public static SharedDefaultFileRegion.SharedFileChannel share(java.nio.channels.FileChannel fileChannel)
-
-