[
https://issues.apache.org/jira/browse/PDFBOX-1088?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13091313#comment-13091313
]
Nghi Nguyen commented on PDFBOX-1088:
-------------------------------------
Maruan
After trying your patch, I seem to be getting object id's for every page. In
the document, there is not a bookmark on every page.
Adam,
I was initially trying to get the page map which should contain object id's to
page numbers for bookmarks. I cannot share the PDF I am using but I am testing
this over 50+ pdf documents. Here are the exceptions when I call out the
getPageMap
java.lang.ClassCastException: org.apache.pdfbox.pdmodel.PDPage
org.apache.pdfbox.pdmodel.PDDocument.processListOfPageReferences(PDDocument.java:163)
org.apache.pdfbox.pdmodel.PDDocument.processListOfPageReferences(PDDocument.java:167)
org.apache.pdfbox.pdmodel.PDDocument.processListOfPageReferences(PDDocument.java:167)
org.apache.pdfbox.pdmodel.PDDocument.generatePageMap(PDDocument.java:152)
org.apache.pdfbox.pdmodel.PDDocument.getPageMap(PDDocument.java:242)
> Class PDDocument Method getPageMap returns a ClassCastException
> ---------------------------------------------------------------
>
> Key: PDFBOX-1088
> URL: https://issues.apache.org/jira/browse/PDFBOX-1088
> Project: PDFBox
> Issue Type: Bug
> Components: PDModel
> Affects Versions: 1.6.0
> Environment: Windows XP
> Reporter: Nghi Nguyen
> Fix For: 1.7.0
>
> Attachments: PDDocument.patch
>
>
> Trying to get the map of bookmarks to page numbers by using method getPageMap
> but throws a java.lang.ClassCastException: org.apache.pdfbox.pdmodel.PDPage
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira