Java LongBuffer.put(LongBuffer src)

Syntax

LongBuffer.put(LongBuffer src) has the following syntax.

public LongBuffer put(LongBuffer src)

Example

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


import java.nio.LongBuffer;
//w w  w  .jav a  2 s.  c  om
public class Main {
  public static void main(String[] args) {
    LongBuffer bb = LongBuffer.allocate(10);
    bb.put(1,100L);
    System.out.println(bb.arrayOffset());

  }
}

The code above generates the following result.





















Home »
  Java Tutorial »
    java.nio »




Buffer
ByteBuffer
ByteOrder
CharBuffer
DoubleBuffer
FloatBuffer
IntBuffer
LongBuffer
MappedByteBuffer
ShortBuffer