Package javax.imageio.stream.ImageInputStreamImplTest

Examples of javax.imageio.stream.ImageInputStreamImplTest.BasicImageInputStreamImpl.readShort()


  public void testWriteShot() throws IOException {
    final BasicImageOutputStreamImpl out = new BasicImageOutputStreamImpl(2);
    final ImageInputStream in = new BasicImageInputStreamImpl(out.buff);

    out.writeShort(Short.MAX_VALUE);
    assertEquals(Short.MAX_VALUE, in.readShort());

    out.reset();
    in.reset();
    out.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    in.setByteOrder(ByteOrder.LITTLE_ENDIAN);
View Full Code Here


    out.reset();
    in.reset();
    out.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    in.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    out.writeShort(Short.MAX_VALUE);
    assertEquals(Short.MAX_VALUE, in.readShort());
  }

  public void testWriteInt() throws IOException {
    final BasicImageOutputStreamImpl out = new BasicImageOutputStreamImpl(4);
    final ImageInputStream in = new BasicImageInputStreamImpl(out.buff);
View Full Code Here

  public void testWriteShot() throws IOException {
    final BasicImageOutputStreamImpl out = new BasicImageOutputStreamImpl(2);
    final ImageInputStream in = new BasicImageInputStreamImpl(out.buff);

    out.writeShort(Short.MAX_VALUE);
    assertEquals(Short.MAX_VALUE, in.readShort());

    out.reset();
    in.reset();
    out.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    in.setByteOrder(ByteOrder.LITTLE_ENDIAN);
View Full Code Here

    out.reset();
    in.reset();
    out.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    in.setByteOrder(ByteOrder.LITTLE_ENDIAN);
    out.writeShort(Short.MAX_VALUE);
    assertEquals(Short.MAX_VALUE, in.readShort());
  }

  public void testWriteInt() throws IOException {
    final BasicImageOutputStreamImpl out = new BasicImageOutputStreamImpl(4);
    final ImageInputStream in = new BasicImageInputStreamImpl(out.buff);
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.