Class GoToEmbeddedAction

  • All Implemented Interfaces:

    
    public final class GoToEmbeddedAction
    extends Action
                        

    Action that allows jumping to a PDF file that is embedded in the document.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      String getPdfPath() Relative path to the embedded PDF document.
      int getPageIndex() Page index in the target document to skip to once the action is executed.
      Destination getDestination() Destination of this action.
      boolean isNewWindow() Whether or not a new window should be created for displaying the embedded document.
      ActionType getType() Returns type of action to make down-casting easier.
      boolean equals(Object o)
      int hashCode()
      String toString()
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • GoToEmbeddedAction

        GoToEmbeddedAction(EmbeddedFile targetFile, boolean openInNewWindow)
        Creates action instance.
        Parameters:
        targetFile - Target embedded file, action will be no-op if the embedded file won't be present in the document once the action is executed.
        openInNewWindow - true to open embedded file in a new activity (works only when executed from within PdfActivity), false to replace currently opened file.
      • GoToEmbeddedAction

        GoToEmbeddedAction(EmbeddedFile targetFile, boolean openInNewWindow, List<Action> subActions)
        Creates action instance.
        Parameters:
        targetFile - Target embedded file, action will be no-op if the embedded file won't be present in the document once the action is executed.
        openInNewWindow - true to open embedded file in a new activity (works only when executed from within PdfActivity), false to replace currently opened file.
        subActions - List of sub-actions of this action.
    • Method Detail

      • getPdfPath

        @Nullable() String getPdfPath()

        Relative path to the embedded PDF document.

        Returns:

        Relative path to the target document. null if path to embedded file could not be resolved.

      • getPageIndex

        @IntRange(from = 0) int getPageIndex()

        Page index in the target document to skip to once the action is executed.

        Returns:

        0-indexed page number.

      • getDestination

         Destination getDestination()

        Destination of this action.

        Returns:

        An structure that contains the page index and the particular view of the document that this action points to.

      • isNewWindow

         boolean isNewWindow()

        Whether or not a new window should be created for displaying the embedded document.

        Returns:

        true if a new window should be created for displayed document.

      • getType

        @NonNull() ActionType getType()

        Returns type of action to make down-casting easier.

        Returns:

        Type of this action.