Liferay 6.2-ce-ga5

com.liferay.portal.kernel.io
Class Serializer.BufferQueue

java.lang.Object
  extended by com.liferay.portal.kernel.io.Serializer.BufferQueue
Enclosing class:
Serializer

protected static class Serializer.BufferQueue
extends Object

Represents a descending byte[] queue ordered by array length.

The queue is small enough to simply use a linear scan search for maintaining its order. The entire queue data is held by a SoftReference, so when necessary, GC can release the whole buffer cache.


Field Summary
protected  int count
           
protected  Serializer.BufferNode headBufferNode
           
 
Constructor Summary
protected Serializer.BufferQueue()
           
 
Method Summary
 byte[] dequeue()
           
 void enqueue(byte[] buffer)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

count

protected int count

headBufferNode

protected Serializer.BufferNode headBufferNode
Constructor Detail

Serializer.BufferQueue

protected Serializer.BufferQueue()
Method Detail

enqueue

public void enqueue(byte[] buffer)

dequeue

public byte[] dequeue()

Liferay 6.2-ce-ga5