Package org.jgroups.util

Examples of org.jgroups.util.ByteArrayDataInputStream.readFully()


        assert read == 4;
        assert in.position() == 4;

        in.position(0);
        try {
            in.readFully(buf, 0, buf.length);
            assert false : "readFully() should have thrown an EOFException";
        }
        catch(Exception eof_ex) {
            System.out.println("got exception as expected: " + eof_ex);
            assert eof_ex instanceof EOFException;
View Full Code Here


        assert in.position() == 10;
        assert in.limit() == 14;
        assert in.capacity() == buf.length;
        byte tmp[]=new byte[5];
        try {
            in.readFully(tmp, 0, tmp.length);
            assert false : " should have gotten an exception";
        }
        catch(Exception ex) {
            System.out.println("caught exception as expected: " + ex);
            assert ex instanceof EOFException;
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.