public class BytesSentStreamSinkConduit
extends org.xnio.conduits.AbstractSinkConduit
implements org.xnio.conduits.StreamSinkConduit
StreamSinkConduit
wrapping that wraps around byte-transferring methods to calculate total
number of bytes transferred leveraging JDK 8 version of LongAdder
(via Infinispan).Constructor and Description |
---|
BytesSentStreamSinkConduit(org.xnio.conduits.StreamSinkConduit next) |
Modifier and Type | Method and Description |
---|---|
static long |
getBytesSent() |
long |
transferFrom(FileChannel src,
long position,
long count) |
long |
transferFrom(org.xnio.channels.StreamSourceChannel source,
long count,
ByteBuffer throughBuffer) |
int |
write(ByteBuffer src) |
long |
write(ByteBuffer[] srcs,
int offs,
int len) |
awaitWritable, awaitWritable, flush, getWriteThread, isWriteResumed, isWriteShutdown, resumeWrites, setWriteReadyHandler, suspendWrites, terminateWrites, truncateWrites, wakeupWrites
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public BytesSentStreamSinkConduit(org.xnio.conduits.StreamSinkConduit next)
public long transferFrom(FileChannel src, long position, long count) throws IOException
transferFrom
in interface org.xnio.conduits.StreamSinkConduit
IOException
public long transferFrom(org.xnio.channels.StreamSourceChannel source, long count, ByteBuffer throughBuffer) throws IOException
transferFrom
in interface org.xnio.conduits.StreamSinkConduit
IOException
public int write(ByteBuffer src) throws IOException
write
in interface org.xnio.conduits.StreamSinkConduit
IOException
public long write(ByteBuffer[] srcs, int offs, int len) throws IOException
write
in interface org.xnio.conduits.StreamSinkConduit
IOException
public static long getBytesSent()
Copyright © 2013 JBoss by Red Hat. All rights reserved.