I have extracted the image from the document. I need more details for the extracted image. How to fetch the details(i.e Page number, height, and width).
String pdf;
NodeCollection shapes = interimdoc.getChildNodes(NodeType.SHAPE, true);
int imageIndex = 1;
for (Shape shape : (Iterable<Shape>)shapes)
{
if (shape.hasImage())
{
pdf = AIE.pdfFolder + "FX" +imageIndex + ".pdf";
Document itermDoc = (Document)interimdoc.deepClone(false);
itermDoc.appendChild(itermDoc.importNode(shape.getAncestor(NodeType.SECTION),false,ImportFormatMode.USE_DESTINATION_STYLES));
itermDoc.ensureMinimum();
Node importedShape = itermDoc.importNode(shape, true, ImportFormatMode.USE_DESTINATION_STYLES);
itermDoc.getFirstSection().getBody().getFirstParagraph().appendChild(importedShape);
itermDoc.save(pdf);
imageIndex++;
}
}
kindly do the needful at the earliest