hi,
im using nodes to store the metadata contained in a png file. im adding other metadata to this and then i want to create a file with this information.
im having problems with the buffered reader.
ive tried the two following approaches with no success. its not allowing me to convert the node into an object or a file.
java.lang.ClassCastException
and also
thanks for your help
dex
im using nodes to store the metadata contained in a png file. im adding other metadata to this and then i want to create a file with this information.
im having problems with the buffered reader.
ive tried the two following approaches with no success. its not allowing me to convert the node into an object or a file.
java.lang.ClassCastException
Code:
Iterator iterReader = ImageIO.getImageReadersByFormatName( "PNG" );
ImageReader imageReaders = (ImageReader)iterReader.next();
ImageInputStream iisInput = ImageIO.createImageInputStream((Object) nodeImageMetaData);
imageReaders.setInput(iisInput, false);
BufferedImage biInput = ImageIO.read(iisInput);
and also
Code:
BufferedImage biInput = ImageIO.read((File)nodeImageMetaData);
thanks for your help
dex