Searched refs:ByteOrder (Results 1 - 25 of 52) sorted by relevance

123

/libcore/ojluni/src/main/java/java/nio/
H A DByteOrder.java37 public final class ByteOrder { class
41 private ByteOrder(String name) { method in class:ByteOrder
50 public static final ByteOrder BIG_ENDIAN
51 = new ByteOrder("BIG_ENDIAN");
58 public static final ByteOrder LITTLE_ENDIAN
59 = new ByteOrder("LITTLE_ENDIAN");
72 public static ByteOrder nativeOrder() {
H A DByteBufferAsDoubleBuffer.java35 private final ByteOrder order;
39 int off, ByteOrder order) {
157 public ByteOrder order() {
H A DByteBufferAsFloatBuffer.java34 private final ByteOrder order;
38 int off, ByteOrder order) {
156 public ByteOrder order() {
H A DByteBufferAsIntBuffer.java34 private final ByteOrder order;
38 int off, ByteOrder order) {
156 public ByteOrder order() {
H A DByteBufferAsLongBuffer.java34 private final ByteOrder order;
38 int off, ByteOrder order) {
156 public ByteOrder order() {
H A DByteBufferAsShortBuffer.java34 private final ByteOrder order;
38 int off, ByteOrder order) {
155 public ByteOrder order() {
H A DStringCharBuffer.java123 public ByteOrder order() {
124 return ByteOrder.nativeOrder();
H A DByteBuffer.java118 * ByteOrder} class. The initial order of a byte buffer is always {@link
119 * ByteOrder#BIG_ENDIAN BIG_ENDIAN}.
897 = (Bits.byteOrder() == ByteOrder.BIG_ENDIAN);
904 * a newly-created byte buffer is always {@link ByteOrder#BIG_ENDIAN
909 public final ByteOrder order() {
910 return bigEndian ? ByteOrder.BIG_ENDIAN : ByteOrder.LITTLE_ENDIAN;
917 * either {@link ByteOrder#BIG_ENDIAN BIG_ENDIAN}
918 * or {@link ByteOrder#LITTLE_ENDIAN LITTLE_ENDIAN}
921 public final ByteBuffer order(ByteOrder b
[all...]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/
H A DByteOrderTest.java20 import java.nio.ByteOrder;
25 * Test java.nio.ByteOrder
31 assertEquals(ByteOrder.BIG_ENDIAN.toString(), "BIG_ENDIAN");
32 assertEquals(ByteOrder.LITTLE_ENDIAN.toString(), "LITTLE_ENDIAN");
36 ByteOrder o = ByteOrder.nativeOrder();
37 assertTrue(o == ByteOrder.BIG_ENDIAN || o == ByteOrder.LITTLE_ENDIAN);
H A DByteBufferTest.java23 import java.nio.ByteOrder;
486 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
488 buf.order(ByteOrder.LITTLE_ENDIAN);
489 assertEquals(ByteOrder.LITTLE_ENDIAN, buf.order());
491 buf.order(ByteOrder.BIG_ENDIAN);
492 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
495 buf.order((ByteOrder)null);
496 assertEquals(ByteOrder.LITTLE_ENDIAN, buf.order());
498 buf.order(ByteOrder.BIG_ENDIAN);
821 buf.order(ByteOrder
[all...]
H A DDirectCharBufferTest.java19 import java.nio.ByteOrder;
77 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectDoubleBufferTest.java19 import java.nio.ByteOrder;
76 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectFloatBufferTest.java19 import java.nio.ByteOrder;
77 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectIntBufferTest.java19 import java.nio.ByteOrder;
77 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectLongBufferTest.java19 import java.nio.ByteOrder;
77 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectShortBufferTest.java19 import java.nio.ByteOrder;
77 assertEquals(ByteOrder.BIG_ENDIAN, buf.order());
H A DDirectByteBufferTest.java19 import java.nio.ByteOrder;
70 buf.order(ByteOrder.BIG_ENDIAN);
/libcore/luni/src/test/java/libcore/java/nio/
H A DBufferTest.java28 import java.nio.ByteOrder;
135 b.order(ByteOrder.BIG_ENDIAN).asCharBuffer().get(chars, 1, 4);
137 b.order(ByteOrder.LITTLE_ENDIAN).asCharBuffer().get(chars, 1, 4);
141 b.order(ByteOrder.BIG_ENDIAN).asDoubleBuffer().get(doubles, 1, 1);
145 b.order(ByteOrder.LITTLE_ENDIAN).asDoubleBuffer().get(doubles, 1, 1);
151 b.order(ByteOrder.BIG_ENDIAN).asFloatBuffer().get(floats, 1, 2);
156 b.order(ByteOrder.LITTLE_ENDIAN).asFloatBuffer().get(floats, 1, 2);
163 b.order(ByteOrder.BIG_ENDIAN).asIntBuffer().get(ints, 1, 2);
168 b.order(ByteOrder.LITTLE_ENDIAN).asIntBuffer().get(ints, 1, 2);
175 b.order(ByteOrder
[all...]
H A DOldDirectIntBufferTest.java19 import java.nio.ByteOrder;
30 byteBuffer.order(ByteOrder.nativeOrder());
H A DOldDirectShortBufferTest.java19 import java.nio.ByteOrder;
30 byteBuffer.order(ByteOrder.nativeOrder());
H A DOldAndroidNIOTest.java23 import java.nio.ByteOrder;
75 b.order(ByteOrder.LITTLE_ENDIAN);
77 assertEquals(ByteOrder.BIG_ENDIAN, dupe.order());
78 b.order(ByteOrder.BIG_ENDIAN);
153 b.order(ByteOrder.LITTLE_ENDIAN);
174 b.order(ByteOrder.BIG_ENDIAN);
224 b.order(ByteOrder.LITTLE_ENDIAN);
239 b.order(ByteOrder.BIG_ENDIAN);
255 b.order(ByteOrder.LITTLE_ENDIAN);
267 b.order(ByteOrder
[all...]
/libcore/luni/src/main/java/libcore/io/
H A DMemoryMappedFile.java23 import java.nio.ByteOrder;
77 return new NioBufferIterator(address, (int) size, ByteOrder.nativeOrder() != ByteOrder.BIG_ENDIAN);
84 return new NioBufferIterator(address, (int) size, ByteOrder.nativeOrder() != ByteOrder.LITTLE_ENDIAN);
H A DMemory.java23 import java.nio.ByteOrder;
45 public static int peekInt(byte[] src, int offset, ByteOrder order) {
46 if (order == ByteOrder.BIG_ENDIAN) {
59 public static long peekLong(byte[] src, int offset, ByteOrder order) {
60 if (order == ByteOrder.BIG_ENDIAN) {
83 public static short peekShort(byte[] src, int offset, ByteOrder order) {
84 if (order == ByteOrder.BIG_ENDIAN) {
91 public static void pokeInt(byte[] dst, int offset, int value, ByteOrder order) {
92 if (order == ByteOrder.BIG_ENDIAN) {
105 public static void pokeLong(byte[] dst, int offset, long value, ByteOrder orde
[all...]
/libcore/dalvik/src/main/java/org/apache/harmony/dalvik/ddmc/
H A DChunkHandler.java20 import java.nio.ByteOrder;
30 public static final ByteOrder CHUNK_ORDER = ByteOrder.BIG_ENDIAN;
/libcore/ojluni/src/main/java/sun/nio/ch/
H A DNativeObject.java31 import java.nio.ByteOrder;
365 private static ByteOrder byteOrder = null;
370 * @return An instance of {@link java.nio.ByteOrder}
372 static ByteOrder byteOrder() {
380 case 0x01: byteOrder = ByteOrder.BIG_ENDIAN; break;
381 case 0x08: byteOrder = ByteOrder.LITTLE_ENDIAN; break;

Completed in 344 milliseconds

123