List of usage examples for java.nio LongBuffer array
public final long[] array()
From source file:Main.java
public static void main(String[] args) { LongBuffer longBuffer = LongBuffer.allocate(10); longBuffer.put(100);/*w ww . ja v a 2s. com*/ longBuffer.rewind(); LongBuffer longBuffer2 = longBuffer.compact(); System.out.println(Arrays.toString(longBuffer2.array())); }
From source file:Main.java
public static void main(String[] args) { LongBuffer longBuffer = LongBuffer.allocate(10); longBuffer.put(100);/*from ww w . j ava 2s.c om*/ longBuffer.rewind(); LongBuffer longBuffer2 = longBuffer.asReadOnlyBuffer(); System.out.println(Arrays.toString(longBuffer2.array())); }
From source file:Main.java
public static void main(String[] args) { LongBuffer bb = LongBuffer.wrap(new long[] { 0, 1, 2, 3, 4, 5, 6 }); bb.put(100);// w w w . j av a2s . com System.out.println(Arrays.toString(bb.array())); }
From source file:Main.java
public static void main(String[] args) { LongBuffer bb = LongBuffer.allocate(10); bb.put(100L);//from w ww. j a v a 2 s . co m bb.rewind(); LongBuffer longBuffer2 = LongBuffer.allocate(10); longBuffer2.put(bb); System.out.println(Arrays.toString(longBuffer2.array())); }
From source file:Main.java
public static void main(String[] args) { LongBuffer bb = LongBuffer.wrap(new long[] { 0, 1, 2, 3, 4, 5, 6 }, 0, 3); bb.put(100L);//from w ww . jav a 2 s. co m System.out.println(Arrays.toString(bb.array())); }