Enum BookmarkDestinations

  • All Implemented Interfaces:
    Serializable, Comparable<BookmarkDestinations>

    public enum BookmarkDestinations
    extends Enum<BookmarkDestinations>
    Destination type that controls how a PDF reader displays the target page when a bookmark or internal hyperlink is followed.

    Mirrors IronPdf.Bookmarks.BookmarkDestinations on the C# side. The Enum.ordinal() of each value is what the engine expects on the wire, so the order of entries below must match the C# enum.

    Corresponds to the PDF 1.7 specification ยง12.3.2 "Explicit Destinations".

    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      PAGE
      Fit the entire destination page within the window (PDF /Fit).
      PAGE_BOUNDS
      Fit the bounding box of the destination page into the window (PDF /FitB).
      PAGE_BOUNDS_X
      Scroll to an X coordinate while fitting the bounding box height to the window (PDF /FitBV).
      PAGE_BOUNDS_Y
      Scroll to a Y coordinate while fitting the bounding box width to the window (PDF /FitBH).
      PAGE_RECT
      Fit the specified rectangle of the destination page into the window (PDF /FitR).
      PAGE_X
      Scroll to a specific X coordinate on the destination page while fitting the page height to the window (PDF /FitV).
      PAGE_Y
      Scroll to a specific Y coordinate on the destination page while fitting the page width to the window (PDF /FitH).
      PAGE_ZOOM
      Scroll to a specific position and zoom level (PDF /XYZ).
    • Enum Constant Detail

      • PAGE

        public static final BookmarkDestinations PAGE
        Fit the entire destination page within the window (PDF /Fit). No additional coordinates are used.
      • PAGE_Y

        public static final BookmarkDestinations PAGE_Y
        Scroll to a specific Y coordinate on the destination page while fitting the page width to the window (PDF /FitH). Uses destinationTop.
      • PAGE_X

        public static final BookmarkDestinations PAGE_X
        Scroll to a specific X coordinate on the destination page while fitting the page height to the window (PDF /FitV). Uses destinationLeft.
      • PAGE_ZOOM

        public static final BookmarkDestinations PAGE_ZOOM
        Scroll to a specific position and zoom level (PDF /XYZ). Uses destinationLeft, destinationTop, and destinationZoom. A destinationZoom of 0 means "inherit the current zoom".
      • PAGE_RECT

        public static final BookmarkDestinations PAGE_RECT
        Fit the specified rectangle of the destination page into the window (PDF /FitR). Uses destinationLeft, destinationBottom, destinationRight, and destinationTop.
      • PAGE_BOUNDS

        public static final BookmarkDestinations PAGE_BOUNDS
        Fit the bounding box of the destination page into the window (PDF /FitB). No additional coordinates are used.
      • PAGE_BOUNDS_Y

        public static final BookmarkDestinations PAGE_BOUNDS_Y
        Scroll to a Y coordinate while fitting the bounding box width to the window (PDF /FitBH). Uses destinationTop.
      • PAGE_BOUNDS_X

        public static final BookmarkDestinations PAGE_BOUNDS_X
        Scroll to an X coordinate while fitting the bounding box height to the window (PDF /FitBV). Uses destinationLeft.
    • Method Detail

      • values

        public static BookmarkDestinations[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (BookmarkDestinations c : BookmarkDestinations.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static BookmarkDestinations valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null