Package javax.imageio.stream

Examples of javax.imageio.stream.ImageOutputStream.reset()


            int pos = 0;
            try {
                ios.mark();
                do {
                    if (pos + 4 > length) {
                        ios.reset();
                        ios.mark();
                        pos = 0;
                    }
                    ios.writeInt(0);
                    pos += 4;
View Full Code Here


                    pos += 4;
                } while (--numReps >= 0);
            } catch (IOException e) {
                e.printStackTrace();
            } finally {
                try { ios.reset(); } catch (IOException e) {}
            }
        }
    }

    private static class IOSWriteFloat extends OutputStreamTests {
View Full Code Here

            int pos = 0;
            try {
                ios.mark();
                do {
                    if (pos + 4 > length) {
                        ios.reset();
                        ios.mark();
                        pos = 0;
                    }
                    ios.writeFloat(0.0f);
                    pos += 4;
View Full Code Here

                    pos += 4;
                } while (--numReps >= 0);
            } catch (IOException e) {
                e.printStackTrace();
            } finally {
                try { ios.reset(); } catch (IOException e) {}
            }
        }
    }

    private static class IOSWriteLong extends OutputStreamTests {
View Full Code Here

            int pos = 0;
            try {
                ios.mark();
                do {
                    if (pos + 8 > length) {
                        ios.reset();
                        ios.mark();
                        pos = 0;
                    }
                    ios.writeLong(0L);
                    pos += 8;
View Full Code Here

                    pos += 8;
                } while (--numReps >= 0);
            } catch (IOException e) {
                e.printStackTrace();
            } finally {
                try { ios.reset(); } catch (IOException e) {}
            }
        }
    }

    private static class IOSWriteDouble extends OutputStreamTests {
View Full Code Here

            int pos = 0;
            try {
                ios.mark();
                do {
                    if (pos + 8 > length) {
                        ios.reset();
                        ios.mark();
                        pos = 0;
                    }
                    ios.writeDouble(0.0);
                    pos += 8;
View Full Code Here

                    pos += 8;
                } while (--numReps >= 0);
            } catch (IOException e) {
                e.printStackTrace();
            } finally {
                try { ios.reset(); } catch (IOException e) {}
            }
        }
    }
}
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.