Save This Page
Home » openjdk-7 » java » nio » [javadoc | source]
java.nio
final class: BufferFactory [javadoc | source]
java.lang.Object
   java.nio.BufferFactory
Provide factory service of buffer classes.

Since all buffer impl classes are package private (except DirectByteBuffer), this factory is the only entrance to access buffer functions from outside of the impl package.

Method from java.nio.BufferFactory Summary:
newByteBuffer,   newByteBuffer,   newCharBuffer,   newCharBuffer,   newCharBuffer,   newDirectByteBuffer,   newDoubleBuffer,   newDoubleBuffer,   newFloatBuffer,   newFloatBuffer,   newIntBuffer,   newIntBuffer,   newLongBuffer,   newLongBuffer,   newShortBuffer,   newShortBuffer
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.nio.BufferFactory Detail:
 public static ByteBuffer newByteBuffer(byte[] array) 
    Returns a new byte buffer based on the specified byte array.
 public static ByteBuffer newByteBuffer(int capacity) 
    Returns a new array based byte buffer with the specified capacity.
 public static CharBuffer newCharBuffer(char[] array) 
    Returns a new char buffer based on the specified char array.
 public static CharBuffer newCharBuffer(CharSequence chseq) 
    Returns a new readonly char buffer based on the specified char sequence.
 public static CharBuffer newCharBuffer(int capacity) 
    Returns a new array based char buffer with the specified capacity.
 public static ByteBuffer newDirectByteBuffer(int capacity) 
    Returns a new direct byte buffer with the specified capacity.
 public static DoubleBuffer newDoubleBuffer(double[] array) 
    Returns a new double buffer based on the specified double array.
 public static DoubleBuffer newDoubleBuffer(int capacity) 
    Returns a new array based double buffer with the specified capacity.
 public static FloatBuffer newFloatBuffer(float[] array) 
    Returns a new float buffer based on the specified float array.
 public static FloatBuffer newFloatBuffer(int capacity) 
    Returns a new array based float buffer with the specified capacity.
 public static IntBuffer newIntBuffer(int capacity) 
    Returns a new array based int buffer with the specified capacity.
 public static IntBuffer newIntBuffer(int[] array) 
    Returns a new int buffer based on the specified int array.
 public static LongBuffer newLongBuffer(int capacity) 
    Returns a new array based long buffer with the specified capacity.
 public static LongBuffer newLongBuffer(long[] array) 
    Returns a new long buffer based on the specified long array.
 public static ShortBuffer newShortBuffer(int capacity) 
    Returns a new array based short buffer with the specified capacity.
 public static ShortBuffer newShortBuffer(short[] array) 
    Returns a new short buffer based on the specified short array.