org.apache.http.nio.util
Class ExpandableBuffer

java.lang.Object
  extended by org.apache.http.nio.util.ExpandableBuffer
All Implemented Interfaces:
BufferInfo
Direct Known Subclasses:
SessionInputBufferImpl, SessionOutputBufferImpl, SharedInputBuffer, SharedOutputBuffer, SimpleInputBuffer, SimpleOutputBuffer

public class ExpandableBuffer
extends java.lang.Object
implements BufferInfo


Field Summary
protected  java.nio.ByteBuffer buffer
           
static int INPUT_MODE
           
static int OUTPUT_MODE
           
 
Constructor Summary
ExpandableBuffer(int buffersize, ByteBufferAllocator allocator)
           
 
Method Summary
 int available()
           
 int capacity()
           
protected  void clear()
           
protected  void ensureCapacity(int requiredCapacity)
           
protected  void expand()
           
protected  int getMode()
           
 boolean hasData()
           
 int length()
           
protected  void setInputMode()
           
protected  void setOutputMode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

INPUT_MODE

public static final int INPUT_MODE
See Also:
Constant Field Values

OUTPUT_MODE

public static final int OUTPUT_MODE
See Also:
Constant Field Values

buffer

protected java.nio.ByteBuffer buffer
Constructor Detail

ExpandableBuffer

public ExpandableBuffer(int buffersize,
                        ByteBufferAllocator allocator)
Method Detail

getMode

protected int getMode()

setOutputMode

protected void setOutputMode()

setInputMode

protected void setInputMode()

expand

protected void expand()

ensureCapacity

protected void ensureCapacity(int requiredCapacity)

capacity

public int capacity()
Specified by:
capacity in interface BufferInfo

hasData

public boolean hasData()

length

public int length()
Specified by:
length in interface BufferInfo

available

public int available()
Specified by:
available in interface BufferInfo

clear

protected void clear()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2005-2008 Apache Software Foundation. All Rights Reserved.