Enum ImageProcessingMode

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<ImageProcessingMode>

    public enum ImageProcessingMode
    extends java.lang.Enum<ImageProcessingMode>

    The mode for processing images in OCR

    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      IF_NO_TEXT
      Process images only if the document contains no text at all.
      NONE
      Do not process images.
      REMOVE_TEXT
      Remove existing OCR text without performing new OCR.
      REPLACE_TEXT
      Process all images and remove existing OCR text.
      UPDATE_TEXT
      Only process images that have no OCR text.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static ImageProcessingMode valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static ImageProcessingMode[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • UPDATE_TEXT

        public static final ImageProcessingMode UPDATE_TEXT
        Only process images that have no OCR text. This is the recommended mode to make scanned pages searchable while preserving existing OCR text.
      • REPLACE_TEXT

        public static final ImageProcessingMode REPLACE_TEXT
        Process all images and remove existing OCR text. Use this mode to re-OCR all images, replacing any previously generated text.
      • REMOVE_TEXT

        public static final ImageProcessingMode REMOVE_TEXT
        Remove existing OCR text without performing new OCR. This mode does not require an OCR engine.
      • IF_NO_TEXT

        public static final ImageProcessingMode IF_NO_TEXT
        Process images only if the document contains no text at all.
    • Method Detail

      • values

        public static ImageProcessingMode[] 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 (ImageProcessingMode c : ImageProcessingMode.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ImageProcessingMode valueOf​(java.lang.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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null