Java DoubleBuffer.toString()

Syntax

DoubleBuffer.toString() has the following syntax.

public String toString()

Example

In the following code shows how to use DoubleBuffer.toString() method.


import java.nio.DoubleBuffer;
/*from   w w  w  .  j  a  v  a  2 s  . c o  m*/
public class Main {
  private static final int BSIZE = 1024;

  public static void main(String[] args) {
    DoubleBuffer bb = DoubleBuffer.allocate(BSIZE);

    bb.put(98765);
    System.out.println(bb.toString());

  }
}

The code above generates the following result.





















Home »
  Java Tutorial »
    java.nio »




Buffer
ByteBuffer
ByteOrder
CharBuffer
DoubleBuffer
FloatBuffer
IntBuffer
LongBuffer
MappedByteBuffer
ShortBuffer