Package org.jgroups.util

Examples of org.jgroups.util.RingBuffer.capacity()


public class RingBufferTest {

    public void testConstructor() {
        RingBuffer buf=new RingBuffer(100, 1);
        System.out.println("buf = " + buf);
        assert buf.capacity() == Util.getNextHigherPowerOfTwo(100);
        assert buf.size() == 0;
    }

    public void testIndex() {
        RingBuffer<Integer> buf=new RingBuffer<Integer>(10, 5);
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.