[I cannot be cast to [B

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web2

  • via jmrtd by *anonymous
  • via Stack Overflow by user3597285
  • Stack trace

    • javax.imageio.IIOException: [I cannot be cast to [B at org.jmrtd.imageio.JJ2000ImageWriter.write( at javax.imageio.ImageWriter.write( at org.jmrtd.jj2000.test.ImageTest.<init>( at org.jmrtd.jj2000.test.ImageTest.main( Caused by: java.lang.ClassCastException: [I cannot be cast to [B at sun.awt.image.ByteInterleavedRaster.getDataElements( at org.jmrtd.imageio.JJ2000ImageWriter.write( ... 3 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    We couldn't find other users who have seen this exception.