Java LongBuffer.isDirect()

Syntax

LongBuffer.isDirect() has the following syntax.

public abstract boolean isDirect()

Example

In the following code shows how to use LongBuffer.isDirect() method.


import java.nio.LongBuffer;
//  w  w  w.  ja  va 2  s  .  com
public class Main {
  public static void main(String[] args) {
    LongBuffer bb = LongBuffer.allocate(10);
    bb.put(100);
    System.out.println(bb.isDirect());

  }
}

The code above generates the following result.





















Home »
  Java Tutorial »
    java.nio »




Buffer
ByteBuffer
ByteOrder
CharBuffer
DoubleBuffer
FloatBuffer
IntBuffer
LongBuffer
MappedByteBuffer
ShortBuffer