Java ShortBuffer.put(short[] src)
Syntax
ShortBuffer.put(short[] src) has the following syntax.
public final ShortBuffer put(short[] src)
Example
In the following code shows how to use ShortBuffer.put(short[] src) method.
import java.nio.ShortBuffer;
/*from w w w . j av a 2s . c o m*/
public class Main {
public static void main(String[] args) {
ShortBuffer bb = ShortBuffer.allocate(10);
bb.put(new short[]{100,123});
System.out.println(bb.arrayOffset());
}
}
The code above generates the following result.