Enum Class PageFit

java.lang.Object
java.lang.Enum<PageFit>
io.scanbot.sdk.pdfgeneration.PageFit
All Implemented Interfaces:
Serializable, Comparable<PageFit>, Constable

public enum PageFit extends Enum<PageFit>
Page fit.
  • Enum Constant Details

    • FIT_IN

      public static final PageFit FIT_IN
      Fit image into page. May leave white borders if the aspect ratio of the image and the page don't match. Preserves image aspect ratio.
    • FILL_IN

      public static final PageFit FILL_IN
      Fill page with image. Will crop the image if the aspect ratio of the image and the page don't match. Preserves image aspect ratio.
    • STRETCH

      public static final PageFit STRETCH
      Stretch image to fill the entire page. The image will never be cropped and there will never be any white borders left, but the image aspect ratio will be made to match the page aspect ratio.
    • NONE

      public static final PageFit NONE
      No resizing, centers the image on the page. The physical size of the image will be determined by the `dpi` parameter.
  • Method Details

    • values

      public static PageFit[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static PageFit valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null