Package java.io

Examples of java.io.LineNumberInputStream.skip()


        byte[] data = {12, 13, 10, 23, 11, 13, 12, 10, 13};
        byte[] expected = {12, 10, 23, 11, 10, 12, 10, 10};

        LineNumberInputStream in =
            new LineNumberInputStream(new ByteArrayInputStream(data));
        long skipped = in.skip(3); // skip 3 bytes
        if ((skipped == 3) && ((in.read()) != 11)) {
            throw new
                RuntimeException("LineNumberInputStream.skip - " +
                                 "unexpected results!");
        }
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.