APIdia Launch Partner
Top Description Fields Constructors Methods
com.sun.xml.internal.stream.util

public Class BufferAllocator

extends Object
Class Inheritance
Imports
java.lang.ref.*

Buffer allocator for buffers of sizes 128 B, 2 KB and 8 KB. Includes methods for allocating and freeing buffers.
Authors
Binu John, Santiago PericasGeertsen

Field Summary

Modifier and TypeField and Description
private static final int
pack-priv byte[]
pack-priv char[]
private static final int
pack-priv byte[]
pack-priv char[]
private static final int
pack-priv byte[]
pack-priv char[]

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public byte[]
getByteBuffer(int size)

public char[]
getCharBuffer(int size)

public void
returnByteBuffer(byte[] b)

public void
returnCharBuffer(char[] c)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

LARGE_SIZE_LIMITback to summary
private static final int LARGE_SIZE_LIMIT
largeByteBufferback to summary
pack-priv byte[] largeByteBuffer
largeCharBufferback to summary
pack-priv char[] largeCharBuffer
MEDIUM_SIZE_LIMITback to summary
private static final int MEDIUM_SIZE_LIMIT
mediumByteBufferback to summary
pack-priv byte[] mediumByteBuffer
mediumCharBufferback to summary
pack-priv char[] mediumCharBuffer
SMALL_SIZE_LIMITback to summary
private static final int SMALL_SIZE_LIMIT
smallByteBufferback to summary
pack-priv byte[] smallByteBuffer
smallCharBufferback to summary
pack-priv char[] smallCharBuffer

Constructor Detail

BufferAllocatorback to summary
public BufferAllocator()

Method Detail

getByteBufferback to summary
public byte[] getByteBuffer(int size)
getCharBufferback to summary
public char[] getCharBuffer(int size)
returnByteBufferback to summary
public void returnByteBuffer(byte[] b)
returnCharBufferback to summary
public void returnCharBuffer(char[] c)