Package net.rubyeye.xmemcached.buffer

Examples of net.rubyeye.xmemcached.buffer.IoBuffer.order()


  }

  public void testAllocate() {
    IoBuffer buffer = this.allocator.allocate(64);
    assertNotNull(buffer);
    assertEquals(ByteOrder.BIG_ENDIAN, buffer.order());
    assertNotNull(buffer.getByteBuffer());

    assertEquals(64, buffer.capacity());
    assertEquals(0, buffer.position());
    assertEquals(64, buffer.limit());
View Full Code Here


    assertTrue(buffer.hasRemaining());
    buffer.position(64);
    assertFalse(buffer.hasRemaining());

    buffer.order(ByteOrder.LITTLE_ENDIAN);
    assertEquals(ByteOrder.LITTLE_ENDIAN, buffer.order());
    buffer.order(ByteOrder.BIG_ENDIAN);

    buffer.position(4);
    buffer.flip();
View Full Code Here

    assertTrue(buffer.hasRemaining());
    buffer.position(64);
    assertFalse(buffer.hasRemaining());

    buffer.order(ByteOrder.LITTLE_ENDIAN);
    assertEquals(ByteOrder.LITTLE_ENDIAN, buffer.order());
    buffer.order(ByteOrder.BIG_ENDIAN);

    buffer.position(4);
    buffer.flip();
    assertEquals(0, buffer.position());
View Full Code Here

    buffer.position(64);
    assertFalse(buffer.hasRemaining());

    buffer.order(ByteOrder.LITTLE_ENDIAN);
    assertEquals(ByteOrder.LITTLE_ENDIAN, buffer.order());
    buffer.order(ByteOrder.BIG_ENDIAN);

    buffer.position(4);
    buffer.flip();
    assertEquals(0, buffer.position());
    assertEquals(4, buffer.limit());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.