Example usage for org.apache.pdfbox.pdmodel.interactive.action PDAnnotationAdditionalActions getPI

List of usage examples for org.apache.pdfbox.pdmodel.interactive.action PDAnnotationAdditionalActions getPI

Introduction

In this page you can find the example usage for org.apache.pdfbox.pdmodel.interactive.action PDAnnotationAdditionalActions getPI.

Prototype

public PDAction getPI() 

Source Link

Document

This will get an action to be performed when the page containing the annotation is no longer visible in the viewer application's user interface.

Usage

From source file:org.apache.tika.parser.pdf.AbstractPDF2XHTML.java

License:Apache License

private void handleWidget(PDAnnotationWidget widget) throws TikaException, SAXException, IOException {
    if (widget == null) {
        return;/*from   ww  w  . j av  a 2 s.  com*/
    }
    handleDestinationOrAction(widget.getAction(), ActionTrigger.ANNOTATION_WIDGET);
    PDAnnotationAdditionalActions annotationActions = widget.getActions();
    if (annotationActions != null) {
        handleDestinationOrAction(annotationActions.getBl(), ActionTrigger.ANNOTATION_LOSE_INPUT_FOCUS);
        handleDestinationOrAction(annotationActions.getD(), ActionTrigger.ANNOTATION_MOUSE_CLICK);
        handleDestinationOrAction(annotationActions.getE(), ActionTrigger.ANNOTATION_CURSOR_ENTERS);
        handleDestinationOrAction(annotationActions.getFo(), ActionTrigger.ANNOTATION_RECEIVES_FOCUS);
        handleDestinationOrAction(annotationActions.getPC(), ActionTrigger.ANNOTATION_PAGE_CLOSED);
        handleDestinationOrAction(annotationActions.getPI(), ActionTrigger.ANNOTATION_PAGE_NO_LONGER_VISIBLE);
        handleDestinationOrAction(annotationActions.getPO(), ActionTrigger.ANNOTATION_PAGE_OPENED);
        handleDestinationOrAction(annotationActions.getPV(), ActionTrigger.ANNOTATION_PAGE_VISIBLE);
        handleDestinationOrAction(annotationActions.getU(), ActionTrigger.ANNOTATION_MOUSE_RELEASED);
        handleDestinationOrAction(annotationActions.getX(), ActionTrigger.ANNOTATION_CURSOR_EXIT);
    }

}