throw new PDFParseException("Can't parse annotations: " + annots.toString());
}
PDFObject[] array = annots.getArray();
for (PDFObject object : array) {
try {
PDFAnnotation pdfAnnot = PDFAnnotation.createAnnotation(object);
if(pdfAnnot != null) {
annotationList.add(pdfAnnot);
}
}catch (PDFParseException e) {
// do nothing, annotations could not be parsed and links will not be displayed.