public class LeakTrackingByteBufferPool extends org.eclipse.jetty.util.component.ContainerLifeCycle implements ByteBufferPool
org.eclipse.jetty.util.component.AbstractLifeCycle.AbstractLifeCycleListenerByteBufferPool.Bucket, ByteBufferPool.Lease| 构造器和说明 |
|---|
LeakTrackingByteBufferPool(ByteBufferPool delegate) |
| 限定符和类型 | 方法和说明 |
|---|---|
ByteBuffer |
acquire(int size,
boolean direct)
Requests a
ByteBuffer of the given size. |
void |
clearTracking() |
long |
getLeakedAcquires() |
long |
getLeakedReleases() |
long |
getLeakedResources() |
protected void |
leaked(org.eclipse.jetty.util.LeakDetector.LeakInfo leakInfo) |
void |
release(ByteBuffer buffer)
Returns a
ByteBuffer, usually obtained with ByteBufferPool.acquire(int, boolean)
(but not necessarily), making it available for recycling and reuse. |
addBean, addBean, addBean, addEventListener, addManaged, contains, destroy, doStart, doStop, dump, dump, dump, dump, dump, dumpBeans, dumpObject, dumpStdErr, dumpThis, getBean, getBeans, getBeans, isManaged, manage, removeBean, removeBeans, removeEventListener, setBeans, setStopTimeout, start, stop, unmanage, updateBean, updateBean, updateBeansaddLifeCycleListener, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stopclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitnewByteBufferpublic LeakTrackingByteBufferPool(ByteBufferPool delegate)
public ByteBuffer acquire(int size, boolean direct)
ByteBufferPoolRequests a ByteBuffer of the given size.
The returned buffer may have a bigger capacity than the size being requested but it will have the limit set to the given size.
acquire 在接口中 ByteBufferPoolsize - the size of the bufferdirect - whether the buffer must be direct or notByteBufferPool.release(ByteBuffer)public void release(ByteBuffer buffer)
ByteBufferPoolReturns a ByteBuffer, usually obtained with ByteBufferPool.acquire(int, boolean)
(but not necessarily), making it available for recycling and reuse.
release 在接口中 ByteBufferPoolbuffer - the buffer to returnByteBufferPool.acquire(int, boolean)public void clearTracking()
public long getLeakedAcquires()
public long getLeakedReleases()
public long getLeakedResources()
protected void leaked(org.eclipse.jetty.util.LeakDetector.LeakInfo leakInfo)
Copyright © 2017. All rights reserved.