SK.gnome.twain
Class TwainSource

java.lang.Object
  extended by SK.gnome.twain.TwainSource
All Implemented Interfaces:
java.awt.image.ImageProducer, MorenaConstants, MorenaSource, TwainConstants

public class TwainSource
extends java.lang.Object
implements TwainConstants, MorenaSource

Java wrapper for TWAIN DS.

For more information about various capabilities see TWAIN Specification (version 1.9).


Nested Class Summary
 class TwainSource.Frame
           
 
Field Summary
 
Fields inherited from interface SK.gnome.twain.TwainConstants
BW, CENTIMETERS, CIEXYZ, CMY, CMYK, CONDITION_CODE_STRING, DS_ENABLED, DS_OPEN, DSM_LOADED, DSM_OPEN, GRAY, INCHES, INVALID, LANDSCAPE, PALETTE, PICAS, PIXELS, POINTS, PORTRAIT, PRESESSION, RESULT_CODE_STRING, RGB, ROT0, ROT180, ROT270, ROT90, STATE_STRING, TRANSFER_READY, TRANSFERRING, TWAF_AIFF, TWAF_AU, TWAF_SND, TWAF_WAV, TWAL_ALARM, TWAL_BARCODE, TWAL_DOUBLEFEED, TWAL_FEEDERERROR, TWAL_FEEDERWARNING, TWAL_JAM, TWAL_PATCHCODE, TWAL_POWER, TWAL_SKEW, TWBD_HORZ, TWBD_HORZVERT, TWBD_VERT, TWBD_VERTHORZ, TWBO_LSBFIRST, TWBO_MSBFIRST, TWBR_CUSTHALFTONE, TWBR_DIFFUSION, TWBR_HALFTONES, TWBR_THRESHOLD, TWBT_2OF5DATALOGIC, TWBT_2OF5IATA, TWBT_2OF5INDUSTRIAL, TWBT_2OF5INTERLEAVED, TWBT_2OF5MATRIX, TWBT_2OF5NONINTERLEAVED, TWBT_3OF9, TWBT_3OF9FULLASCII, TWBT_CODABAR, TWBT_CODABARWITHSTARTSTOP, TWBT_CODE128, TWBT_CODE93, TWBT_EAN13, TWBT_EAN8, TWBT_MAXICODE, TWBT_PDF417, TWBT_POSTNET, TWBT_UCC128, TWBT_UPCA, TWBT_UPCE, TWCB_AUTO, TWCB_CLEAR, TWCB_NOCLEAR, TWCP_BITFIELDS, TWCP_GROUP31D, TWCP_GROUP31DEOL, TWCP_GROUP32D, TWCP_GROUP4, TWCP_JBIG, TWCP_JPEG, TWCP_LZW, TWCP_NONE, TWCP_PACKBITS, TWCP_PNG, TWCP_RLE4, TWCP_RLE8, TWDE_CHECKAUTOMATICCAPTURE, TWDE_CHECKBATTERY, TWDE_CHECKFLASH, TWDE_CHECKPOWERSUPPLY, TWDE_CHECKRESOLUTION, TWDE_CUSTOMEVENTS, TWDE_DEVICEADDED, TWDE_DEVICEOFFLINE, TWDE_DEVICEREADY, TWDE_DEVICEREMOVED, TWDE_IMAGECAPTURED, TWDE_IMAGEDELETED, TWDE_LAMPFAILURE, TWDE_PAPERDOUBLEFEED, TWDE_PAPERJAM, TWDE_POWERDOWNNOTIFY, TWDX_1PASSDUPLEX, TWDX_2PASSDUPLEX, TWDX_NONE, TWFA_CENTER, TWFA_LEFT, TWFA_NONE, TWFA_RIGHT, TWFF_BMP, TWFF_EXIF, TWFF_FPX, TWFF_JFIF, TWFF_PICT, TWFF_PNG, TWFF_SPIFF, TWFF_TIFF, TWFF_TIFFMULTI, TWFF_XBM, TWFL_AUTO, TWFL_NONE, TWFL_OFF, TWFL_ON, TWFL_REDEYE, TWFO_FIRSTPAGEFIRST, TWFO_LASTPAGEFIRST, TWFR_BOOK, TWFR_FANFOLD, TWFT_BLACK, TWFT_BLUE, TWFT_CYAN, TWFT_GREEN, TWFT_MAGENTA, TWFT_NONE, TWFT_RED, TWFT_WHITE, TWFT_YELLOW, TWIF_AUTO, TWIF_BANDPASS, TWIF_HIGHPASS, TWIF_LOWPASS, TWIF_NONE, TWIPS, TWJC_JSIC, TWJC_JSIS, TWJC_JSXC, TWJC_JSXS, TWJC_NONE, TWJQ_HIGH, TWJQ_LOW, TWJQ_MEDIUM, TWJQ_UNKNOWN, TWLG_AFRIKAANS, TWLG_ALBANIA, TWLG_ARABIC, TWLG_ARABIC_ALGERIA, TWLG_ARABIC_BAHRAIN, TWLG_ARABIC_EGYPT, TWLG_ARABIC_IRAQ, TWLG_ARABIC_JORDAN, TWLG_ARABIC_KUWAIT, TWLG_ARABIC_LEBANON, TWLG_ARABIC_LIBYA, TWLG_ARABIC_MOROCCO, TWLG_ARABIC_OMAN, TWLG_ARABIC_QATAR, TWLG_ARABIC_SAUDIARABIA, TWLG_ARABIC_SYRIA, TWLG_ARABIC_TUNISIA, TWLG_ARABIC_UAE, TWLG_ARABIC_YEMEN, TWLG_ASSAMESE, TWLG_BASQUE, TWLG_BENGALI, TWLG_BIHARI, TWLG_BODO, TWLG_BULGARIAN, TWLG_BYELORUSSIAN, TWLG_CATALAN, TWLG_CHINESE, TWLG_CHINESE_HONGKONG, TWLG_CHINESE_PRC, TWLG_CHINESE_SIMPLIFIED, TWLG_CHINESE_SINGAPORE, TWLG_CHINESE_TAIWAN, TWLG_CHINESE_TRADITIONAL, TWLG_CROATIA, TWLG_CZECH, TWLG_DAN, TWLG_DANISH, TWLG_DOGRI, TWLG_DUT, TWLG_DUTCH, TWLG_DUTCH_BELGIAN, TWLG_ENG, TWLG_ENGLISH, TWLG_ENGLISH_AUSTRALIAN, TWLG_ENGLISH_CANADIAN, TWLG_ENGLISH_IRELAND, TWLG_ENGLISH_NEWZEALAND, TWLG_ENGLISH_SOUTHAFRICA, TWLG_ENGLISH_UK, TWLG_ENGLISH_USA, TWLG_ESTONIAN, TWLG_FAEROESE, TWLG_FARSI, TWLG_FCF, TWLG_FIN, TWLG_FINNISH, TWLG_FRENCH, TWLG_FRENCH_BELGIAN, TWLG_FRENCH_CANADIAN, TWLG_FRENCH_LUXEMBOURG, TWLG_FRENCH_SWISS, TWLG_FRN, TWLG_GER, TWLG_GERMAN, TWLG_GERMAN_AUSTRIAN, TWLG_GERMAN_LIECHTENSTEIN, TWLG_GERMAN_LUXEMBOURG, TWLG_GERMAN_SWISS, TWLG_GREEK, TWLG_GUJARATI, TWLG_HARYANVI, TWLG_HEBREW, TWLG_HINDI, TWLG_HUNGARIAN, TWLG_ICE, TWLG_ICELANDIC, TWLG_INDONESIAN, TWLG_ITALIAN, TWLG_ITALIAN_SWISS, TWLG_ITN, TWLG_JAPANESE, TWLG_KANNADA, TWLG_KASHMIRI, TWLG_KOREAN, TWLG_KOREAN_JOHAB, TWLG_LATVIAN, TWLG_LITHUANIAN, TWLG_MALAYALAM, TWLG_MARATHI, TWLG_MARWARI, TWLG_MEGHALAYAN, TWLG_MIZO, TWLG_NAGA, TWLG_NOR, TWLG_NORWEGIAN, TWLG_NORWEGIAN_BOKMAL, TWLG_NORWEGIAN_NYNORSK, TWLG_ORISSI, TWLG_POLISH, TWLG_POR, TWLG_PORTUGUESE, TWLG_PORTUGUESE_BRAZIL, TWLG_PUNJABI, TWLG_PUSHTU, TWLG_ROMANIAN, TWLG_RUSSIAN, TWLG_SERBIAN_CYRILLIC, TWLG_SERBIAN_LATIN, TWLG_SIKKIMI, TWLG_SLOVAK, TWLG_SLOVENIAN, TWLG_SPA, TWLG_SPANISH, TWLG_SPANISH_MEXICAN, TWLG_SPANISH_MODERN, TWLG_SWE, TWLG_SWEDISH, TWLG_SWEDISH_FINLAND, TWLG_TAMIL, TWLG_TELUGU, TWLG_THAI, TWLG_TRIPURI, TWLG_TURKISH, TWLG_UKRANIAN, TWLG_URDU, TWLG_USA, TWLG_USERLOCALE, TWLG_VIETNAMESE, TWLP_REFLECTIVE, TWLP_TRANSMISSIVE, TWLS_BLUE, TWLS_GREEN, TWLS_IR, TWLS_NONE, TWLS_RED, TWLS_UV, TWLS_WHITE, TWNF_AUTO, TWNF_LONEPIXEL, TWNF_MAJORITYRULE, TWNF_NONE, TWOR_LANDSCAPE, TWOR_PORTRAIT, TWOR_ROT0, TWOR_ROT180, TWOR_ROT270, TWOR_ROT90, TWOV_ALL, TWOV_AUTO, TWOV_LEFTRIGHT, TWOV_NONE, TWOV_TOPBOTTOM, TWPC_CHUNKY, TWPC_PLANAR, TWPF_CHOCOLATE, TWPF_VANILLA, TWPR_ENDORSERBOTTOMAFTER, TWPR_ENDORSERBOTTOMBEFORE, TWPR_ENDORSERTOPAFTER, TWPR_ENDORSERTOPBEFORE, TWPR_IMPRINTERBOTTOMAFTER, TWPR_IMPRINTERBOTTOMBEFORE, TWPR_IMPRINTERTOPAFTER, TWPR_IMPRINTERTOPBEFORE, TWPT_BW, TWPT_CIEXYZ, TWPT_CMY, TWPT_CMYK, TWPT_GRAY, TWPT_PALETTE, TWPT_RGB, TWPT_YUV, TWPT_YUVK, TWSS_2A0, TWSS_4A0, TWSS_A0, TWSS_A1, TWSS_A10, TWSS_A2, TWSS_A3, TWSS_A4, TWSS_A4LETTER, TWSS_A5, TWSS_A6, TWSS_A7, TWSS_A8, TWSS_A9, TWSS_B3, TWSS_B4, TWSS_B5LETTER, TWSS_B6, TWSS_BUSINESSCARD, TWSS_C0, TWSS_C1, TWSS_C10, TWSS_C2, TWSS_C3, TWSS_C4, TWSS_C5, TWSS_C6, TWSS_C7, TWSS_C8, TWSS_C9, TWSS_ISOB0, TWSS_ISOB1, TWSS_ISOB10, TWSS_ISOB2, TWSS_ISOB3, TWSS_ISOB4, TWSS_ISOB5, TWSS_ISOB6, TWSS_ISOB7, TWSS_ISOB8, TWSS_ISOB9, TWSS_JISB0, TWSS_JISB1, TWSS_JISB10, TWSS_JISB2, TWSS_JISB3, TWSS_JISB4, TWSS_JISB5, TWSS_JISB6, TWSS_JISB7, TWSS_JISB8, TWSS_JISB9, TWSS_NONE, TWSS_USEXECUTIVE, TWSS_USLEDGER, TWSS_USLEGAL, TWSS_USLETTER, TWSS_USSTATEMENT, TWSX_FILE, TWSX_FILE2, TWSX_MEMORY, TWSX_NATIVE, TWTY_BOOL, TWTY_FIX32, TWTY_INT16, TWTY_INT32, TWTY_INT8, TWTY_STR1024, TWTY_STR128, TWTY_STR255, TWTY_STR32, TWTY_STR64, TWTY_UINT16, TWTY_UINT32, TWTY_UINT8, TWUN_CENTIMETERS, TWUN_INCHES, TWUN_PICAS, TWUN_PIXELS, TWUN_POINTS, TWUN_TWIPS, YUV, YUVK
 
Fields inherited from interface SK.gnome.morena.MorenaConstants
MORENA_MESSAGES, VERSION
 
Method Summary
 void acquireImage(boolean uiVisible, java.awt.image.ImageConsumer[] consumers)
          Starts image production.
 void acquireImage(boolean uiVisible, java.lang.String fileName, int format)
          Saves image to file using Twain file transfer mode.
 void addConsumer(java.awt.image.ImageConsumer consumer)
          This method is used to register an ImageConsumer with the ImageProducer for access to the image data during a later reconstruction of the Image.
 void clearPage()
          Sets ICAP_CLEARPAGE capability value to true.
 boolean endOfJob()
          Checks if there are more pages in current job.
 void feedPage()
          Sets ICAP_FEEDPAGE capability value to true.
 int getActualBitsPerPixel()
          Gets TW_IMAGEINFO.BitsPerPixel.
 int getActualImageLength()
          Gets TW_IMAGEINFO.ImageLength.
 int getActualImageWidth()
          Gets TW_IMAGEINFO.ImageWidth.
 int getActualPixelType()
          Gets TW_IMAGEINFO.PixelType.
 double getActualXResolution()
          Gets TW_IMAGEINFO.XResolution.
 double getActualYResolution()
          Gets TW_IMAGEINFO.YResolution.
 int getAlarmVolume()
          Gets CAP_ALARMVOLUME capability value.
 int getAudioFileFormat()
          Gets ACAP_AUDIOFILEFORMAT capability value.
 int getAudioTransferMech()
          Gets ACAP_XFERMECH capability value.
 java.lang.String getAuthor()
          Gets CAP_AUTHOR capability value.
 boolean getAutoBright()
          Gets ICAP_AUTOBRIGHT capability value.
 boolean getAutoFeed()
          Gets CAP_AUTOFEED capability value.
 boolean getAutomaticBorderDetection()
          Gets ICAP_AUTOMATICBORDERDETECTION capability value.
 int getAutomaticCapture()
          Gets CAP_AUTOMATICCAPTURE capability value.
 boolean getAutomaticDeskew()
          Gets ICAP_AUTOMATICDESKEW capability value.
 boolean getAutomaticRotate()
          Gets ICAP_AUTOMATICROTATE capability value.
 boolean getAutoScan()
          Gets CAP_AUTOSCAN capability value.
 boolean getBarCodeDetectionEnabled()
          Gets ICAP_BARCODEDETECTIONENABLED capability value.
 int getBarCodeMaxRetries()
          Gets ICAP_BARCODEMAXRETRIES capability value.
 int getBarCodeMaxSearchPriorities()
          Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability value.
 int getBarCodeSearchMode()
          Gets ICAP_BARCODESEARCHMODE capability value.
 int getBarCodeTimeout()
          Gets ICAP_BARCODETIMEOUT capability value.
 int getBatteryMinutes()
          Gets CAP_BATTERYMINUTES capability value.
 int getBatteryPercentage()
          Gets CAP_BATTERYPERCENTAGE capability value.
 int getBitDepth()
          Gets ICAP_BITDEPTH capability value.
 int getBitDepthReduction()
          Gets ICAP_BITDEPTHREDUCTION capability value.
 int getBitOrder()
          Gets ICAP_BITORDER capability value.
 int getBitOrderCodes()
          Gets ICAP_BITORDERCODES capability value.
 double getBrightness()
          Gets ICAP_BRIGHTNESS capability value.
 boolean getCameraPreviewUI()
          Gets CAP_CAMERAPREVIEWUI capability value.
 java.lang.String getCaption()
          Gets CAP_CAPTION capability value.
 int getCCITTKFactor()
          Gets ICAP_CCITTKFACTOR capability value.
 int getClearBuffers()
          Gets CAP_CLEARBUFFERS capability value.
 int getCompression()
          Gets ICAP_COMPRESSION capability value.
 int getConditionCode()
          Gets last TWAIN operation condition code.
 double getContrast()
          Gets ICAP_CONTRAST capability value.
 boolean getCustomDSData()
          Gets CAP_CUSTOMDSDATA capability value.
 int getDefaultAudioFileFormat()
          Gets ACAP_AUDIOFILEFORMAT capability default value.
See getAudioFileFormat() for description.
 int getDefaultAudioTransferMech()
          Gets ACAP_XFERMECH capability default value.
See getAudioTransferMech() for description.
 int getDefaultBarCodeMaxRetries()
          Gets ICAP_BARCODEMAXRETRIES capability default value.
See getBarCodeMaxRetries() for description.
 int getDefaultBarCodeMaxSearchPriorities()
          Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability default value.
See getBarCodeMaxSearchPriorities() for description.
 int getDefaultBarCodeSearchMode()
          Gets ICAP_BARCODESEARCHMODE capability default value.
See getBarCodeSearchMode() for description.
 int getDefaultBarCodeTimeout()
          Gets ICAP_BARCODETIMEOUT capability default value.
See getBarCodeTimeout() for description.
 int getDefaultBitDepth()
          Gets ICAP_BITDEPTH capability default value.
See getBitDepth() for description.
 int getDefaultBitDepthReduction()
          Gets ICAP_BITDEPTHREDUCTION capability default value.
See getBitDepthReduction() for description.
 int getDefaultBitOrder()
          Gets ICAP_BITORDER capability default value.
See getBitOrder() for description.
 int getDefaultBitOrderCodes()
          Gets ICAP_BITORDERCODES capability default value.
See getBitOrderCodes() for description.
 double getDefaultBrightness()
          Gets ICAP_BRIGHTNESS capability default value.
See getBrightness() for description.
 int getDefaultCompression()
          Gets ICAP_COMPRESSION capability default value.
See getCompression() for description.
 double getDefaultContrast()
          Gets ICAP_CONTRAST capability default value.
See getContrast() for description.
 double getDefaultExposureTime()
          Gets ICAP_EXPOSURETIME capability default value.
See getExposureTime() for description.
 int getDefaultFlashUsed()
          Gets ICAP_FLASHUSED2 capability default value.
See getFlashUsed() for description.
 double getDefaultHighlight()
          Gets ICAP_HIGHLIGHT capability default value.
See getHighlight() for description.
 int getDefaultImageFileFormat()
          Gets ICAP_IMAGEFILEFORMAT capability default value.
See getImageFileFormat() for description.
 int getDefaultImageFilter()
          Gets ICAP_IMAGEFILTER capability default value.
See getImageFilter() for description.
 int getDefaultJobControl()
          Gets CAP_JOBCONTROL capability default value.
See getJobControl() for description.
 int getDefaultJPEGPixelType()
          Gets ICAP_JPEGPIXELTYPE capability default value.
See getJPEGPixelType() for description.
 int getDefaultJPEGQuality()
          Gets ICAP_JPEGQUALITY capability default value.
See getJPEGQuality() for description.
 boolean getDefaultLampState()
          Gets ICAP_LAMPSTATE capability default value.
See getLampState() for description.
 int getDefaultLanguage()
          Gets CAP_LANGUAGE capability default value.
See getLanguage() for description.
 int getDefaultLightPath()
          Gets ICAP_LIGHTPATH capability default value.
See getLightPath() for description.
 int getDefaultLightSource()
          Gets ICAP_LIGHTSOURCE capability default value.
See getLightSource() for description.
 int getDefaultMaxBatchBuffers()
          Gets CAP_MAXBATCHBUFFERS capability default value.
See getMaxBatchBuffers() for description.
 int getDefaultNoiseFilter()
          Gets ICAP_NOISEFILTER capability default value.
See getNoiseFilter() for description.
 int getDefaultOrientation()
          Gets ICAP_ORIENTATION capability default value.
See getOrientation() for description.
 int getDefaultOverscan()
          Gets ICAP_OVERSCAN capability default value.
See getOverscan() for description.
 int getDefaultPatchCodeMaxRetries()
          Gets ICAP_PATCHCODEMAXRETRIES capability default value.
See getPatchCodeMaxRetries() for description.
 int getDefaultPatchCodeMaxSearchPriorities()
          Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability default value.
See getPatchCodeMaxSearchPriorities() for description.
 int getDefaultPatchCodeSearchMode()
          Gets ICAP_PATCHCODESEARCHMODE capability default value.
See getPatchCodeSearchMode() for description.
 int getDefaultPatchCodeTimeout()
          Gets ICAP_PATCHCODETIMEOUT capability default value.
See getPatchCodeTimeout() for description.
 int getDefaultPixelFlavor()
          Gets ICAP_PIXELFLAVOR capability default value.
See getPixelFlavor() for description.
 int getDefaultPixelFlavorCodes()
          Gets ICAP_PIXELFLAVORCODES capability default value.
See getPixelFlavorCodes() for description.
 int getDefaultPixelType()
          Gets ICAP_PIXELTYPE capability default value.
See getPixelType() for description.
 int getDefaultPlanarChunky()
          Gets ICAP_PLANARCHUNKY capability default value.
See getPlanarChunky() for description.
 int getDefaultPowerSupply()
          Gets CAP_POWERSUPPLY capability default value.
See getPowerSupply() for description.
 int getDefaultPrinter()
          Gets CAP_PRINTER capability default value.
See getPrinter() for description.
 int getDefaultPrinterMode()
          Gets CAP_PRINTERMODE capability default value.
See getPrinterMode() for description.
 double getDefaultRotation()
          Gets ICAP_ROTATION capability default value.
See getRotation() for description.
 double getDefaultShadow()
          Gets ICAP_SHADOW capability default value.
See getShadow() for description.
 int getDefaultSupportedSizes()
          Gets ICAP_SUPPORTEDSIZES capability default value.
See getSupportedSizes() for description.
 double getDefaultThreshold()
          Gets ICAP_THRESHOLD capability default value.
See getThreshold() for description.
 int getDefaultTransferMech()
          Gets ICAP_XFERMECH capability default value.
See getTransferMech() for description.
 int getDefaultUnits()
          Gets ICAP_UNITS capability default value.
See getUnits() for description.
 double getDefaultXNativeResolution()
          Gets ICAP_XNATIVERESOLUTION capability default value.
See getXNativeResolution() for description.
 double getDefaultXResolution()
          Gets ICAP_XRESOLUTION capability default value.
See getXResolution() for description.
 double getDefaultXScaling()
          Gets ICAP_XSCALING capability default value.
See getXScaling() for description.
 double getDefaultYNativeResolution()
          Gets ICAP_YNATIVERESOLUTION capability default value.
See getYNativeResolution() for description.
 double getDefaultYResolution()
          Gets ICAP_YRESOLUTION capability default value.
See getYResolution() for description.
 double getDefaultYScaling()
          Gets ICAP_YSCALING capability default value.
See getYScaling() for description.
 int getDefaultZoomFactor()
          Gets ICAP_ZOOMFACTOR capability default value.
See getZoomFactor() for description.
 boolean getDeviceOnLine()
          Gets CAP_DEVICEONLINE capability value.
 java.lang.String getDeviceTimeDate()
          Gets CAP_DEVICETIMEDATE capability value.
 double getDoubleCapability(java.lang.String name, int capability, int twty)
          Some Twain drivers have capabilities not defined in the Twain specification.
 int getDuplex()
          Gets CAP_DUPLEX capability value.
 boolean getDuplexEnabled()
          Gets CAP_DUPLEXENABLED capability value.
 boolean getEnableDSUIOnly()
          Gets CAP_ENABLEDSUIONLY capability value.
 int getEndorser()
          Gets CAP_ENDORSER capability value.
 double getExposureTime()
          Gets ICAP_EXPOSURETIME capability value.
 boolean getExtImageInfo()
          Gets ICAP_EXTIMAGEINFO capability value.
 int getFeederAlignment()
          Gets CAP_FEEDERALIGNMENT capability value.
 boolean getFeederEnabled()
          Gets CAP_FEEDERENABLED capability value.
 boolean getFeederLoaded()
          Gets CAP_FEEDERLOADED capability value.
 int getFeederOrder()
          Gets CAP_FEEDERORDER capability value.
 int getFilter()
          Gets ICAP_FILTER capability value.
 int getFlashUsed()
          Gets ICAP_FLASHUSED2 capability value.
 int getFlipRotation()
          Gets ICAP_FLIPROTATION capability value.
 TwainSource.Frame getFrame()
          Returns frame for last acquired image.
 double getGamma()
          Gets ICAP_GAMMA capability value.
 java.lang.String getHalftones()
          Gets ICAP_HALFTONES capability value.
 double getHighlight()
          Gets ICAP_HIGHLIGHT capability value.
 int getIdentity()
          Gets source TW_IDENTITY structure pointer for use in non-JavaTwain JNI code.
 int getImageDataSet()
          Gets ICAP_IMAGEDATASET capability value.
 int getImageFileFormat()
          Gets ICAP_IMAGEFILEFORMAT capability value.
 int getImageFilter()
          Gets ICAP_IMAGEFILTER capability value.
 boolean getIndicators()
          Gets CAP_INDICATORS capability value.
 int getIntCapability(java.lang.String name, int capability, int twty)
          Some Twain drivers have capabilities not defined in the Twain specification.
 int getJobControl()
          Gets CAP_JOBCONTROL capability value.
 int getJPEGPixelType()
          Gets ICAP_JPEGPIXELTYPE capability value.
 int getJPEGQuality()
          Gets ICAP_JPEGQUALITY capability value.
 boolean getLampState()
          Gets ICAP_LAMPSTATE capability value.
 int getLanguage()
          Gets CAP_LANGUAGE capability value.
 int getLightPath()
          Gets ICAP_LIGHTPATH capability value.
 int getLightSource()
          Gets ICAP_LIGHTSOURCE capability value.
 int getMaxBatchBuffers()
          Gets CAP_MAXBATCHBUFFERS capability value.
 double getMinimumHeight()
          Gets ICAP_MINIMUMHEIGHT capability value.
 double getMinimumWidth()
          Gets ICAP_MINIMUMWIDTH capability value.
 int getNoiseFilter()
          Gets ICAP_NOISEFILTER capability value.
 int getOrientation()
          Gets ICAP_ORIENTATION capability value.
 int getOverscan()
          Gets ICAP_OVERSCAN capability value.
 boolean getPaperDetectable()
          Gets CAP_PAPERDETECTABLE capability value.
 boolean getPatchCodeDetectionEnabled()
          Gets ICAP_PATCHCODEDETECTIONENABLED capability value.
 int getPatchCodeMaxRetries()
          Gets ICAP_PATCHCODEMAXRETRIES capability value.
 int getPatchCodeMaxSearchPriorities()
          Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability value.
 int getPatchCodeSearchMode()
          Gets ICAP_PATCHCODESEARCHMODE capability value.
 int getPatchCodeTimeout()
          Gets ICAP_PATCHCODETIMEOUT capability value.
 double getPhysicalHeight()
          Gets ICAP_PHYSICALHEIGHT capability value.
 double getPhysicalWidth()
          Gets ICAP_PHYSICALWIDTH capability value.
 int getPixelFlavor()
          Gets ICAP_PIXELFLAVOR capability value.
 int getPixelFlavorCodes()
          Gets ICAP_PIXELFLAVORCODES capability value.
 int getPixelType()
          Gets ICAP_PIXELTYPE capability value.
 int getPlanarChunky()
          Gets ICAP_PLANARCHUNKY capability value.
 int getPowerSupply()
          Gets CAP_POWERSUPPLY capability value.
 int getPrinter()
          Gets CAP_PRINTER capability value.
 boolean getPrinterEnabled()
          Gets CAP_PRINTERENABLED capability value.
 int getPrinterIndex()
          Gets CAP_PRINTERINDEX capability value.
 int getPrinterMode()
          Gets CAP_PRINTERMODE capability value.
 java.lang.String getPrinterString()
          Gets CAP_PRINTERSTRING capability value.
 java.lang.String getPrinterSuffix()
          Gets CAP_PRINTERSUFFIX capability value.
 double getResolution()
          Combines getXResolution and getYResolution capability to one common method.
 int getResultCode()
          Gets last TWAIN operation result code.
 double getRotation()
          Gets ICAP_ROTATION capability value.
 java.lang.String getSerialNumber()
          Gets CAP_SERIALNUMBER capability value.
 double getShadow()
          Gets ICAP_SHADOW capability value.
 int getState()
          Gets TWAIN DS state.
 java.lang.String getStringCapability(java.lang.String name, int capability, int twty)
          Some Twain drivers have capabilities not defined in the Twain specification.
 int[] getSupportedAudioFileFormat()
          Gets ACAP_AUDIOFILEFORMAT capability supported values.
See getAudioFileFormat() for description.
 int[] getSupportedAudioTransferMech()
          Gets ACAP_XFERMECH capability supported values.
See getAudioTransferMech() for description.
 int[] getSupportedBarCodeMaxRetries()
          Gets ICAP_BARCODEMAXRETRIES capability supported values.
See getBarCodeMaxRetries() for description.
 int[] getSupportedBarCodeMaxSearchPriorities()
          Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability supported values.
See getBarCodeMaxSearchPriorities() for description.
 int[] getSupportedBarCodeSearchMode()
          Gets ICAP_BARCODESEARCHMODE capability supported values.
See getBarCodeSearchMode() for description.
 int[] getSupportedBarCodeTimeout()
          Gets ICAP_BARCODETIMEOUT capability supported values.
See getBarCodeTimeout() for description.
 int[] getSupportedBitDepth()
          Gets ICAP_BITDEPTH capability supported values.
See getBitDepth() for description.
 int[] getSupportedBitDepthReduction()
          Gets ICAP_BITDEPTHREDUCTION capability supported values.
See getBitDepthReduction() for description.
 int[] getSupportedBitOrder()
          Gets ICAP_BITORDER capability supported values.
See getBitOrder() for description.
 int[] getSupportedBitOrderCodes()
          Gets ICAP_BITORDERCODES capability supported values.
See getBitOrderCodes() for description.
 double[] getSupportedBrightness()
          Gets ICAP_BRIGHTNESS capability supported values.
See getBrightness() for description.
 int[] getSupportedCompression()
          Gets ICAP_COMPRESSION capability supported values.
See getCompression() for description.
 double[] getSupportedContrast()
          Gets ICAP_CONTRAST capability supported values.
See getContrast() for description.
 double[] getSupportedExposureTime()
          Gets ICAP_EXPOSURETIME capability supported values.
See getExposureTime() for description.
 int[] getSupportedFlashUsed()
          Gets ICAP_FLASHUSED2 capability supported values.
See getFlashUsed() for description.
 double[] getSupportedHighlight()
          Gets ICAP_HIGHLIGHT capability supported values.
See getHighlight() for description.
 int[] getSupportedImageFileFormat()
          Gets ICAP_IMAGEFILEFORMAT capability supported values.
See getImageFileFormat() for description.
 int[] getSupportedImageFilter()
          Gets ICAP_IMAGEFILTER capability supported values.
See getImageFilter() for description.
 int[] getSupportedJobControl()
          Gets CAP_JOBCONTROL capability supported values.
See getJobControl() for description.
 int[] getSupportedJPEGPixelType()
          Gets ICAP_JPEGPIXELTYPE capability supported values.
See getJPEGPixelType() for description.
 int[] getSupportedJPEGQuality()
          Gets ICAP_JPEGQUALITY capability supported values.
See getJPEGQuality() for description.
 boolean[] getSupportedLampState()
          Gets ICAP_LAMPSTATE capability supported values.
See getLampState() for description.
 int[] getSupportedLanguage()
          Gets CAP_LANGUAGE capability supported values.
See getLanguage() for description.
 int[] getSupportedLightPath()
          Gets ICAP_LIGHTPATH capability supported values.
See getLightPath() for description.
 int[] getSupportedLightSource()
          Gets ICAP_LIGHTSOURCE capability supported values.
See getLightSource() for description.
 int[] getSupportedMaxBatchBuffers()
          Gets CAP_MAXBATCHBUFFERS capability supported values.
See getMaxBatchBuffers() for description.
 int[] getSupportedNoiseFilter()
          Gets ICAP_NOISEFILTER capability supported values.
See getNoiseFilter() for description.
 int[] getSupportedOrientation()
          Gets ICAP_ORIENTATION capability supported values.
See getOrientation() for description.
 int[] getSupportedOverscan()
          Gets ICAP_OVERSCAN capability supported values.
See getOverscan() for description.
 int[] getSupportedPatchCodeMaxRetries()
          Gets ICAP_PATCHCODEMAXRETRIES capability supported values.
See getPatchCodeMaxRetries() for description.
 int[] getSupportedPatchCodeMaxSearchPriorities()
          Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability supported values.
See getPatchCodeMaxSearchPriorities() for description.
 int[] getSupportedPatchCodeSearchMode()
          Gets ICAP_PATCHCODESEARCHMODE capability supported values.
See getPatchCodeSearchMode() for description.
 int[] getSupportedPatchCodeTimeout()
          Gets ICAP_PATCHCODETIMEOUT capability supported values.
See getPatchCodeTimeout() for description.
 int getSupportedPatchCodeTypes()
          Gets ICAP_SUPPORTEDPATCHCODETYPES capability value.
 int[] getSupportedPixelFlavor()
          Gets ICAP_PIXELFLAVOR capability supported values.
See getPixelFlavor() for description.
 int[] getSupportedPixelFlavorCodes()
          Gets ICAP_PIXELFLAVORCODES capability supported values.
See getPixelFlavorCodes() for description.
 int[] getSupportedPixelType()
          Gets ICAP_PIXELTYPE capability supported values.
See getPixelType() for description.
 int[] getSupportedPlanarChunky()
          Gets ICAP_PLANARCHUNKY capability supported values.
See getPlanarChunky() for description.
 int[] getSupportedPowerSupply()
          Gets CAP_POWERSUPPLY capability supported values.
See getPowerSupply() for description.
 int[] getSupportedPrinter()
          Gets CAP_PRINTER capability supported values.
See getPrinter() for description.
 int[] getSupportedPrinterMode()
          Gets CAP_PRINTERMODE capability supported values.
See getPrinterMode() for description.
 double[] getSupportedRotation()
          Gets ICAP_ROTATION capability supported values.
See getRotation() for description.
 double[] getSupportedShadow()
          Gets ICAP_SHADOW capability supported values.
See getShadow() for description.
 int getSupportedSizes()
          Gets ICAP_SUPPORTEDSIZES capability value.
 int[] getSupportedSupportedSizes()
          Gets ICAP_SUPPORTEDSIZES capability supported values.
See getSupportedSizes() for description.
 double[] getSupportedThreshold()
          Gets ICAP_THRESHOLD capability supported values.
See getThreshold() for description.
 int[] getSupportedTransferMech()
          Gets ICAP_XFERMECH capability supported values.
See getTransferMech() for description.
 int[] getSupportedUnits()
          Gets ICAP_UNITS capability supported values.
See getUnits() for description.
 double[] getSupportedXNativeResolution()
          Gets ICAP_XNATIVERESOLUTION capability supported values.
See getXNativeResolution() for description.
 double[] getSupportedXResolution()
          Gets ICAP_XRESOLUTION capability supported values.
See getXResolution() for description.
 double[] getSupportedXScaling()
          Gets ICAP_XSCALING capability supported values.
See getXScaling() for description.
 double[] getSupportedYNativeResolution()
          Gets ICAP_YNATIVERESOLUTION capability supported values.
See getYNativeResolution() for description.
 double[] getSupportedYResolution()
          Gets ICAP_YRESOLUTION capability supported values.
See getYResolution() for description.
 double[] getSupportedYScaling()
          Gets ICAP_YSCALING capability supported values.
See getYScaling() for description.
 int[] getSupportedZoomFactor()
          Gets ICAP_ZOOMFACTOR capability supported values.
See getZoomFactor() for description.
 double getThreshold()
          Gets ICAP_THRESHOLD capability value.
 boolean getThumbnailsEnabled()
          Gets CAP_THUMBNAILSENABLED capability value.
 int getTimeBeforeFirstCapture()
          Gets CAP_TIMEBEFOREFIRSTCAPTURE capability value.
 int getTimeBetweenCaptures()
          Gets CAP_TIMEBETWEENCAPTURES capability value.
 java.lang.String getTimeDate()
          Gets CAP_TIMEDATE capability value.
 int getTimeFill()
          Gets ICAP_TIMEFILL capability value.
 int getTransferCount()
          Gets CAP_XFERCOUNT capability value.
 int getTransferMech()
          Gets ICAP_XFERMECH capability value.
 boolean getUIControllable()
          Gets CAP_UICONTROLLABLE capability value.
 boolean getUndefinedImageSize()
          Gets ICAP_UNDEFINEDIMAGESIZE capability value.
 int getUnits()
          Gets ICAP_UNITS capability value.
 double getXNativeResolution()
          Gets ICAP_XNATIVERESOLUTION capability value.
 double getXResolution()
          Gets ICAP_XRESOLUTION capability value.
 double getXScaling()
          Gets ICAP_XSCALING capability value.
 double getYNativeResolution()
          Gets ICAP_YNATIVERESOLUTION capability value.
 double getYResolution()
          Gets ICAP_YRESOLUTION capability value.
 double getYScaling()
          Gets ICAP_YSCALING capability value.
 int getZoomFactor()
          Gets ICAP_ZOOMFACTOR capability value.
 boolean hasMoreImages()
          Checks if there are more images to transfer.
 boolean isConsumer(java.awt.image.ImageConsumer consumer)
          This method determines if a given ImageConsumer object is currently registered with this ImageProducer as one of its consumers.
 boolean maskBadValueException(boolean mask)
          Masks some TwainException.
maskBadValueException(true) masks all TwainException raised setCapability()/getCapability() methods by because of TWRC_FAILURE/TWCC_BADVALUE result/condition code until maskBadValueException(false) is invoked.
Default value is true.
 boolean maskUnsupportedCapabilityException(boolean mask)
          Masks some TwainException.
maskUnsupportedCapabilityException(true) masks all TwainException raised setCapability()/getCapability() methods by because of TWRC_FAILURE/TWCC_CAPUNSUPPORTED result/condition code until maskUnsupportedCapabilityException(false) is invoked.
Default value is true.
 void removeConsumer(java.awt.image.ImageConsumer consumer)
          This method removes the given ImageConsumer object from the list of consumers currently registered to receive image data.
 void requestTopDownLeftRightResend(java.awt.image.ImageConsumer consumer)
          Not used.
 void rewindPage()
          Sets ICAP_REWINDPAGE capability value to true.
 void setAlarmVolume(int value)
          Sets CAP_ALARMVOLUME capability value.
See getAlarmVolume() for description.
 void setAudioFileFormat(int value)
          Sets ACAP_AUDIOFILEFORMAT capability value.
See getAudioFileFormat() for description.
 void setAudioTransferMech(int value)
          Sets ACAP_XFERMECH capability value.
See getAudioTransferMech() for description.
 void setAuthor(java.lang.String value)
          Sets CAP_AUTHOR capability value.
See getAuthor() for description.
 void setAutoBright(boolean value)
          Sets ICAP_AUTOBRIGHT capability value.
See getAutoBright() for description.
 void setAutoFeed(boolean value)
          Sets CAP_AUTOFEED capability value.
See getAutoFeed() for description.
 void setAutomaticBorderDetection(boolean value)
          Sets ICAP_AUTOMATICBORDERDETECTION capability value.
See getAutomaticBorderDetection() for description.
 void setAutomaticCapture(int value)
          Sets CAP_AUTOMATICCAPTURE capability value.
See getAutomaticCapture() for description.
 void setAutomaticDeskew(boolean value)
          Sets ICAP_AUTOMATICDESKEW capability value.
See getAutomaticDeskew() for description.
 void setAutomaticRotate(boolean value)
          Sets ICAP_AUTOMATICROTATE capability value.
See getAutomaticRotate() for description.
 void setAutoScan(boolean value)
          Sets CAP_AUTOSCAN capability value.
See getAutoScan() for description.
 void setBarCodeDetectionEnabled(boolean value)
          Sets ICAP_BARCODEDETECTIONENABLED capability value.
See getBarCodeDetectionEnabled() for description.
 void setBarCodeMaxRetries(int value)
          Sets ICAP_BARCODEMAXRETRIES capability value.
See getBarCodeMaxRetries() for description.
 void setBarCodeMaxSearchPriorities(int value)
          Sets ICAP_BARCODEMAXSEARCHPRIORITIES capability value.
See getBarCodeMaxSearchPriorities() for description.
 void setBarCodeSearchMode(int value)
          Sets ICAP_BARCODESEARCHMODE capability value.
See getBarCodeSearchMode() for description.
 void setBarCodeTimeout(int value)
          Sets ICAP_BARCODETIMEOUT capability value.
See getBarCodeTimeout() for description.
 void setBehaviorMask(int mask)
          Because of some bugs in TWAIN drivers for some popular scanners, Morena implicitly works in a workaround mode.
 void setBitDepth(int value)
          Sets ICAP_BITDEPTH capability value.
See getBitDepth() for description.
 void setBitDepthReduction(int value)
          Sets ICAP_BITDEPTHREDUCTION capability value.
See getBitDepthReduction() for description.
 void setBitOrder(int value)
          Sets ICAP_BITORDER capability value.
See getBitOrder() for description.
 void setBitOrderCodes(int value)
          Sets ICAP_BITORDERCODES capability value.
See getBitOrderCodes() for description.
 void setBrightness(double value)
          Sets ICAP_BRIGHTNESS capability value.
See getBrightness() for description.
 void setBuffer(byte[] byteBuffer)
          Sets ImageProducer buffer.
 void setBuffer(int[] intBuffer)
          Sets ImageProducer buffer.
 void setCaption(java.lang.String value)
          Sets CAP_CAPTION capability value.
See getCaption() for description.
 void setCCITTKFactor(int value)
          Sets ICAP_CCITTKFACTOR capability value.
See getCCITTKFactor() for description.
 void setClearBuffers(int value)
          Sets CAP_CLEARBUFFERS capability value.
See getClearBuffers() for description.
 void setColorMode()
          Sets color scan mode.
 void setCompression(int value)
          Sets ICAP_COMPRESSION capability value.
See getCompression() for description.
 void setContrast(double value)
          Sets ICAP_CONTRAST capability value.
See getContrast() for description.
 void setDeviceTimeDate(java.lang.String value)
          Sets CAP_DEVICETIMEDATE capability value.
See getDeviceTimeDate() for description.
 void setDoubleCapability(java.lang.String name, int capability, int twty, double value)
          Some Twain drivers have capabilities not defined in the Twain specification.
 void setDuplexEnabled(boolean value)
          Sets CAP_DUPLEXENABLED capability value.
See getDuplexEnabled() for description.
 void setEndorser(int value)
          Sets CAP_ENDORSER capability value.
See getEndorser() for description.
 void setExposureTime(double value)
          Sets ICAP_EXPOSURETIME capability value.
See getExposureTime() for description.
 void setExtImageInfo(boolean value)
          Sets ICAP_EXTIMAGEINFO capability value.
See getExtImageInfo() for description.
 void setFeederAlignment(int value)
          Sets CAP_FEEDERALIGNMENT capability value.
See getFeederAlignment() for description.
 void setFeederEnabled(boolean value)
          Sets CAP_FEEDERENABLED capability value.
See getFeederEnabled() for description.
 void setFeederOrder(int value)
          Sets CAP_FEEDERORDER capability value.
See getFeederOrder() for description.
 void setFilter(int value)
          Sets ICAP_FILTER capability value.
See getFilter() for description.
 void setFlashUsed(int value)
          Sets ICAP_FLASHUSED2 capability value.
See getFlashUsed() for description.
 void setFlipRotation(int value)
          Sets ICAP_FLIPROTATION capability value.
See getFlipRotation() for description.
 void setFrame(double left, double top, double right, double bottom)
          Selects frame for image acquire.
 void setFrame(TwainSource.Frame frame)
          Selects frame for image acquire.
 void setGamma(double value)
          Sets ICAP_GAMMA capability value.
See getGamma() for description.
 void setGrayScaleMode()
          Sets gray scale scan mode.
 void setHalftones(java.lang.String value)
          Sets ICAP_HALFTONES capability value.
See getHalftones() for description.
 void setHighlight(double value)
          Sets ICAP_HIGHLIGHT capability value.
See getHighlight() for description.
 void setImageDataSet(int value)
          Sets ICAP_IMAGEDATASET capability value.
See getImageDataSet() for description.
 void setImageFileFormat(int value)
          Sets ICAP_IMAGEFILEFORMAT capability value.
See getImageFileFormat() for description.
 void setImageFilter(int value)
          Sets ICAP_IMAGEFILTER capability value.
See getImageFilter() for description.
 void setIndicators(boolean value)
          Sets CAP_INDICATORS capability value.
See getIndicators() for description.
 void setIntCapability(java.lang.String name, int capability, int twty, int value)
          Some Twain drivers have capabilities not defined in the Twain specification.
 void setJobControl(int value)
          Sets CAP_JOBCONTROL capability value.
See getJobControl() for description.
 void setJPEGPixelType(int value)
          Sets ICAP_JPEGPIXELTYPE capability value.
See getJPEGPixelType() for description.
 void setJPEGQuality(int value)
          Sets ICAP_JPEGQUALITY capability value.
See getJPEGQuality() for description.
 void setLampState(boolean value)
          Sets ICAP_LAMPSTATE capability value.
See getLampState() for description.
 void setLanguage(int value)
          Sets CAP_LANGUAGE capability value.
See getLanguage() for description.
 void setLightPath(int value)
          Sets ICAP_LIGHTPATH capability value.
See getLightPath() for description.
 void setLightSource(int value)
          Sets ICAP_LIGHTSOURCE capability value.
See getLightSource() for description.
 void setMaxBatchBuffers(int value)
          Sets CAP_MAXBATCHBUFFERS capability value.
See getMaxBatchBuffers() for description.
 void setNoiseFilter(int value)
          Sets ICAP_NOISEFILTER capability value.
See getNoiseFilter() for description.
 void setOrientation(int value)
          Sets ICAP_ORIENTATION capability value.
See getOrientation() for description.
 void setOverscan(int value)
          Sets ICAP_OVERSCAN capability value.
See getOverscan() for description.
 void setPatchCodeDetectionEnabled(boolean value)
          Sets ICAP_PATCHCODEDETECTIONENABLED capability value.
See getPatchCodeDetectionEnabled() for description.
 void setPatchCodeMaxRetries(int value)
          Sets ICAP_PATCHCODEMAXRETRIES capability value.
See getPatchCodeMaxRetries() for description.
 void setPatchCodeMaxSearchPriorities(int value)
          Sets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability value.
See getPatchCodeMaxSearchPriorities() for description.
 void setPatchCodeSearchMode(int value)
          Sets ICAP_PATCHCODESEARCHMODE capability value.
See getPatchCodeSearchMode() for description.
 void setPatchCodeTimeout(int value)
          Sets ICAP_PATCHCODETIMEOUT capability value.
See getPatchCodeTimeout() for description.
 void setPixelFlavor(int value)
          Sets ICAP_PIXELFLAVOR capability value.
See getPixelFlavor() for description.
 void setPixelFlavorCodes(int value)
          Sets ICAP_PIXELFLAVORCODES capability value.
See getPixelFlavorCodes() for description.
 void setPixelType(int value)
          Sets ICAP_PIXELTYPE capability value.
See getPixelType() for description.
 void setPlanarChunky(int value)
          Sets ICAP_PLANARCHUNKY capability value.
See getPlanarChunky() for description.
 void setPrinter(int value)
          Sets CAP_PRINTER capability value.
See getPrinter() for description.
 void setPrinterEnabled(boolean value)
          Sets CAP_PRINTERENABLED capability value.
See getPrinterEnabled() for description.
 void setPrinterIndex(int value)
          Sets CAP_PRINTERINDEX capability value.
See getPrinterIndex() for description.
 void setPrinterMode(int value)
          Sets CAP_PRINTERMODE capability value.
See getPrinterMode() for description.
 void setPrinterString(java.lang.String value)
          Sets CAP_PRINTERSTRING capability value.
See getPrinterString() for description.
 void setPrinterSuffix(java.lang.String value)
          Sets CAP_PRINTERSUFFIX capability value.
See getPrinterSuffix() for description.
 void setResolution(double dpi)
          Combines setXResolution and setYResolution capability to one common method.
 void setRotation(double value)
          Sets ICAP_ROTATION capability value.
See getRotation() for description.
 void setShadow(double value)
          Sets ICAP_SHADOW capability value.
See getShadow() for description.
 void setStringCapability(java.lang.String name, int capability, int twty, java.lang.String value)
          Some Twain drivers have capabilities not defined in the Twain specification.
 void setSupportedSizes(int value)
          Sets ICAP_SUPPORTEDSIZES capability value.
See getSupportedSizes() for description.
 void setThreshold(double value)
          Sets ICAP_THRESHOLD capability value.
See getThreshold() for description.
 void setThumbnailsEnabled(boolean value)
          Sets CAP_THUMBNAILSENABLED capability value.
See getThumbnailsEnabled() for description.
 void setTimeBeforeFirstCapture(int value)
          Sets CAP_TIMEBEFOREFIRSTCAPTURE capability value.
See getTimeBeforeFirstCapture() for description.
 void setTimeBetweenCaptures(int value)
          Sets CAP_TIMEBETWEENCAPTURES capability value.
See getTimeBetweenCaptures() for description.
 void setTimeFill(int value)
          Sets ICAP_TIMEFILL capability value.
See getTimeFill() for description.
 void setTransferCount(int value)
          Sets CAP_XFERCOUNT capability value.
See getTransferCount() for description.
 void setTransferMech(int value)
          Sets ICAP_XFERMECH capability value.
See getTransferMech() for description.
 void setUndefinedImageSize(boolean value)
          Sets ICAP_UNDEFINEDIMAGESIZE capability value.
See getUndefinedImageSize() for description.
 void setUnits(int value)
          Sets ICAP_UNITS capability value.
See getUnits() for description.
 void setVisible(boolean uiVisible)
          Sets User Interface window visibility flag for startProduction().
 void setXResolution(double value)
          Sets ICAP_XRESOLUTION capability value.
See getXResolution() for description.
 void setXScaling(double value)
          Sets ICAP_XSCALING capability value.
See getXScaling() for description.
 void setYResolution(double value)
          Sets ICAP_YRESOLUTION capability value.
See getYResolution() for description.
 void setYScaling(double value)
          Sets ICAP_YSCALING capability value.
See getYScaling() for description.
 void setZoomFactor(int value)
          Sets ICAP_ZOOMFACTOR capability value.
See getZoomFactor() for description.
 void startProduction(java.awt.image.ImageConsumer consumer)
          This method both registers the given ImageConsumer object as a consumer and starts an immediate reconstruction of the image data which will then be delivered to this consumer and any other consumer which may have already been registered with the producer.
 java.lang.String toString()
          Returns source identity ProductName field.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

setBuffer

public void setBuffer(int[] intBuffer)
Sets ImageProducer buffer.


setBuffer

public void setBuffer(byte[] byteBuffer)
Sets ImageProducer buffer.


toString

public java.lang.String toString()
Returns source identity ProductName field.

Specified by:
toString in interface MorenaSource
Overrides:
toString in class java.lang.Object

getState

public int getState()
             throws TwainException
Gets TWAIN DS state. Only values TwainConstants.DSM_OPEN, TwainConstants.DS_OPEN, TwainConstants.DS_ENABLED, TwainConstants.TRANSFER_READY and TwainConstants.TRANSFERRING can be returned as DS state.

Throws:
TwainException

getResultCode

public int getResultCode()
                  throws TwainException
Gets last TWAIN operation result code.

Throws:
TwainException

getConditionCode

public int getConditionCode()
                     throws TwainException
Gets last TWAIN operation condition code.

Throws:
TwainException

getIdentity

public int getIdentity()
Gets source TW_IDENTITY structure pointer for use in non-JavaTwain JNI code.


acquireImage

public void acquireImage(boolean uiVisible,
                         java.awt.image.ImageConsumer[] consumers)
                  throws TwainException
Starts image production.

Throws:
TwainException

acquireImage

public void acquireImage(boolean uiVisible,
                         java.lang.String fileName,
                         int format)
                  throws TwainException
Saves image to file using Twain file transfer mode.

Notice: Twain driver is not required to support the file transfer mode.

Example of file transfer mode usage:

     TwainSource source;
     try
     {
       source = TwainManager.selectSource(null);
       int tm[] = source.getSupportedTransferMech();
       boolean fileTransferSupported = false;
       for (int i = 0; i < tm.length; i++)
         if(tm[i] == TWSX_FILE)
           fileTransferSupported = true;
       if(fileTransferSupported)
       {
         System.err.println("File transfer mode is supported");
         int ff[] = source.getSupportedImageFileFormat();
         // Notice: Scanner or camera will acquire images "ff.length" times.
         for (int j = 0; j < ff.length; j++)
         {
           switch (ff[j])
           {
           case TWFF_TIFF:
             System.err.println("TIFF format is supported");
             source.acquireImage(true, "exampleFileSave.tiff", TWFF_TIFF);
             System.err.println(" TIFF Done!");
             break;
           case TWFF_TIFFMULTI:
             System.err.println("TWFF_TIFFMULTI format is supported");
             source.acquireImage(true, "exampleFileSave.tiff", TWFF_TIFFMULTI);
             System.err.println(" TWFF_TIFFMULTI Done!");
             break;
           case TWFF_PNG:
             System.err.println("PNG format is supported");
             source.acquireImage(true, "exampleFileSave.png", TWFF_PNG);
             System.err.println(" PNG Done!");
             break;
           case TWFF_BMP:
             System.err.println("BMP format is supported");
             source.acquireImage(true, "exampleFileSave.bmp", TWFF_BMP);
             System.err.println(" BMP Done!");
             break;
           case TWFF_PICT:
             System.err.println("PICT format is supported");
             source.acquireImage(true, "exampleFileSave.pct", TWFF_PICT);
             System.err.println(" PICT Done!");
             break;
           case TWFF_JFIF:
             System.err.println("JFIF format is supported");
             source.acquireImage(true, "exampleFileSave.jpeg", TWFF_JFIF);
             System.err.println(" JFIF Done!");
             break;
           case TWFF_SPIFF:
             System.err.println("SPIFF format is supported");
             source.acquireImage(true, "exampleFileSave.jpeg", TWFF_SPIFF);
             System.err.println(" SPIFF Done!");
             break;
           default:
             System.err.println("Supported file is different as TIFF, PNG, BMP, PICT, JPEG.");
           }
         }
       } else
         System.err.println("File transfer mode is not supported");
     } catch (TwainException e)
     {
       e.printStackTrace();
     }
     finally
     { try
       { TwainManager.close();
       }
       catch (Exception exception)
       { exception.printStackTrace();
       }
     } 
    

Throws:
TwainException

hasMoreImages

public boolean hasMoreImages()
                      throws TwainException
Checks if there are more images to transfer.

See ADF example in the tutorial to see how to use it.

Throws:
TwainException

endOfJob

public boolean endOfJob()
                 throws TwainException
Checks if there are more pages in current job.

Throws:
TwainException
See Also:
setJobControl(int)

setVisible

public void setVisible(boolean uiVisible)
Sets User Interface window visibility flag for startProduction().

Specified by:
setVisible in interface MorenaSource

setResolution

public void setResolution(double dpi)
                   throws TwainException
Combines setXResolution and setYResolution capability to one common method.

See getXResolution() for description.

Specified by:
setResolution in interface MorenaSource
Throws:
TwainException

getResolution

public double getResolution()
                     throws TwainException
Combines getXResolution and getYResolution capability to one common method.

See getXResolution() for description.

Specified by:
getResolution in interface MorenaSource
Throws:
TwainException

setColorMode

public void setColorMode()
                  throws TwainException
Sets color scan mode.

Specified by:
setColorMode in interface MorenaSource
Throws:
TwainException

setGrayScaleMode

public void setGrayScaleMode()
                      throws TwainException
Sets gray scale scan mode.

Specified by:
setGrayScaleMode in interface MorenaSource
Throws:
TwainException

getFrame

public TwainSource.Frame getFrame()
                           throws TwainException
Returns frame for last acquired image. Uses the units set by the setUnits(int) method. Some Twain drivers ignore unit set by setUnits capability and use their own default one.

Throws:
TwainException

setFrame

public void setFrame(TwainSource.Frame frame)
              throws TwainException
Selects frame for image acquire. Uses the units set by the setUnits(int) method. Some Twain drivers ignore unit set by setUnits capability and use their own default one.

Throws:
TwainException

setFrame

public void setFrame(double left,
                     double top,
                     double right,
                     double bottom)
              throws TwainException
Selects frame for image acquire. Uses the units set by the setUnits(int) method. Some Twain drivers ignore unit set by setUnits capability and use their own default one.

Specified by:
setFrame in interface MorenaSource
Throws:
TwainException

maskUnsupportedCapabilityException

public boolean maskUnsupportedCapabilityException(boolean mask)
                                           throws TwainException
Masks some TwainException.
maskUnsupportedCapabilityException(true) masks all TwainException raised setCapability()/getCapability() methods by because of TWRC_FAILURE/TWCC_CAPUNSUPPORTED result/condition code until maskUnsupportedCapabilityException(false) is invoked.
Default value is true.

Specified by:
maskUnsupportedCapabilityException in interface MorenaSource
Throws:
TwainException

maskBadValueException

public boolean maskBadValueException(boolean mask)
                              throws TwainException
Masks some TwainException.
maskBadValueException(true) masks all TwainException raised setCapability()/getCapability() methods by because of TWRC_FAILURE/TWCC_BADVALUE result/condition code until maskBadValueException(false) is invoked.
Default value is true.

Specified by:
maskBadValueException in interface MorenaSource
Throws:
TwainException

setBehaviorMask

public void setBehaviorMask(int mask)
                     throws TwainException
Because of some bugs in TWAIN drivers for some popular scanners, Morena implicitly works in a workaround mode. To turn off the workaround mode use setBehaviorMask(0) on TwainSource instance. The image acquisition can be more efficient in this case, but on the other hand, if the scanner's driver has the mentioned bug, this will crash the application.

Throws:
TwainException

clearPage

public void clearPage()
               throws TwainException
Sets ICAP_CLEARPAGE capability value to true.

Throws:
TwainException

feedPage

public void feedPage()
              throws TwainException
Sets ICAP_FEEDPAGE capability value to true.

Throws:
TwainException

rewindPage

public void rewindPage()
                throws TwainException
Sets ICAP_REWINDPAGE capability value to true.

Throws:
TwainException

getActualXResolution

public double getActualXResolution()
                            throws TwainException
Gets TW_IMAGEINFO.XResolution. Valid after image acquisition only.

Throws:
TwainException

getActualYResolution

public double getActualYResolution()
                            throws TwainException
Gets TW_IMAGEINFO.YResolution. Valid after image acquisition only.

Throws:
TwainException

getActualImageWidth

public int getActualImageWidth()
                        throws TwainException
Gets TW_IMAGEINFO.ImageWidth. Valid after image acquisition only.

Throws:
TwainException

getActualImageLength

public int getActualImageLength()
                         throws TwainException
Gets TW_IMAGEINFO.ImageLength. Valid after image acquisition only.

Throws:
TwainException

getActualBitsPerPixel

public int getActualBitsPerPixel()
                          throws TwainException
Gets TW_IMAGEINFO.BitsPerPixel. Valid after image acquisition only.

Throws:
TwainException

getActualPixelType

public int getActualPixelType()
                       throws TwainException
Gets TW_IMAGEINFO.PixelType. Valid after image acquisition only.

Throws:
TwainException

setIntCapability

public void setIntCapability(java.lang.String name,
                             int capability,
                             int twty,
                             int value)
                      throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intended for that type of capabilities, although it allows to set any integer capability.

Parameters:
name - Used for debug output.
capability - Capability value specified by the hardware manufacturer.
twty - One of the following value types to correct conversion: TWTY_INT8, TWTY_INT16, TWTY_INT32, TWTY_UINT8, TWTY_UINT16, TWTY_UINT32, TWTY_BOOL.
value - Value to be set.
Throws:
TwainException
Since:
6.4.0.0

For example:
setPixelType(TwainConstants.TWPT_BW)
is the same as
setIntCapability("my_custom_pixel_type", 257, TwainConstants.TWTY_UINT16, TwainConstants.TWPT_BW);

See Also:
TwainConstants

getIntCapability

public int getIntCapability(java.lang.String name,
                            int capability,
                            int twty)
                     throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intended for that type of capabilities to receive a integer value.

Throws:
TwainException
See Also:
setIntCapability(java.lang.String, int, int, int)

setDoubleCapability

public void setDoubleCapability(java.lang.String name,
                                int capability,
                                int twty,
                                double value)
                         throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intend for that type of capabilities, although it allows to set any double capability.

Parameters:
name - Used for debug output.
capability - Capability value specified by the hardware manufacturer.
twty - TwainConstants.TWTY_FIX32.
value - Value to be set.
Throws:
TwainException
Since:
6.4.0.0

For example:
setXResolution(75)
is the same as
setDoubleCapability("my_custom_XResolution", 4376, TwainConstants.TWTY_FIX32, 75);


getDoubleCapability

public double getDoubleCapability(java.lang.String name,
                                  int capability,
                                  int twty)
                           throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intended for that type of capabilities to receive a double value.

Throws:
TwainException
See Also:
setDoubleCapability(java.lang.String, int, int, double)

setStringCapability

public void setStringCapability(java.lang.String name,
                                int capability,
                                int twty,
                                java.lang.String value)
                         throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intend for that type of capabilities, although it allows to set any string capability.

Parameters:
name - Used for debug output.
capability - Capability value specified by the hardware manufacturer.
twty - One of the following value types to correct conversion: TWTY_STR32, TWTY_STR64, TWTY_STR128, TWTY_STR255, TWTY_STR1024.
value - Value to be set.
Throws:
TwainException
Since:
6.4.0.0
See Also:
setIntCapability(java.lang.String, int, int, int), setDoubleCapability(java.lang.String, int, int, double), TwainConstants

getStringCapability

public java.lang.String getStringCapability(java.lang.String name,
                                            int capability,
                                            int twty)
                                     throws TwainException
Some Twain drivers have capabilities not defined in the Twain specification. This method is intend for that type of capabilities to receive a string value.

Throws:
TwainException
See Also:
setStringCapability(java.lang.String, int, int, java.lang.String)

getAudioFileFormat

public int getAudioFileFormat()
                       throws TwainException
Gets ACAP_AUDIOFILEFORMAT capability value. Informs the application which audio file formats the Source can generate. Tells the Source which audio file formats the application can handle.

Throws:
TwainException

getSupportedAudioFileFormat

public int[] getSupportedAudioFileFormat()
                                  throws TwainException
Gets ACAP_AUDIOFILEFORMAT capability supported values.
See getAudioFileFormat() for description.

Throws:
TwainException

getDefaultAudioFileFormat

public int getDefaultAudioFileFormat()
                              throws TwainException
Gets ACAP_AUDIOFILEFORMAT capability default value.
See getAudioFileFormat() for description.

Throws:
TwainException

setAudioFileFormat

public void setAudioFileFormat(int value)
                        throws TwainException
Sets ACAP_AUDIOFILEFORMAT capability value.
See getAudioFileFormat() for description.

Throws:
TwainException

getAudioTransferMech

public int getAudioTransferMech()
                         throws TwainException
Gets ACAP_XFERMECH capability value. Allows the Application and Source to identify which audio transfer mechanisms they have in common.

Throws:
TwainException

getSupportedAudioTransferMech

public int[] getSupportedAudioTransferMech()
                                    throws TwainException
Gets ACAP_XFERMECH capability supported values.
See getAudioTransferMech() for description.

Throws:
TwainException

getDefaultAudioTransferMech

public int getDefaultAudioTransferMech()
                                throws TwainException
Gets ACAP_XFERMECH capability default value.
See getAudioTransferMech() for description.

Throws:
TwainException

setAudioTransferMech

public void setAudioTransferMech(int value)
                          throws TwainException
Sets ACAP_XFERMECH capability value.
See getAudioTransferMech() for description.

Throws:
TwainException

getAlarmVolume

public int getAlarmVolume()
                   throws TwainException
Gets CAP_ALARMVOLUME capability value. The volume of a device's audible alarm. Note that this control affects the volume of all alarms; no specific volume control for individual types of alarms is provided. Take note of the range step, some Sources may only offer a step of 100, which turns the alarm on or off.

Throws:
TwainException

setAlarmVolume

public void setAlarmVolume(int value)
                    throws TwainException
Sets CAP_ALARMVOLUME capability value.
See getAlarmVolume() for description.

Throws:
TwainException

getAuthor

public java.lang.String getAuthor()
                           throws TwainException
Gets CAP_AUTHOR capability value. The name or other identifying information about the Author of the image. It may include a copyright string.

Throws:
TwainException

setAuthor

public void setAuthor(java.lang.String value)
               throws TwainException
Sets CAP_AUTHOR capability value.
See getAuthor() for description.

Throws:
TwainException

getAutoFeed

public boolean getAutoFeed()
                    throws TwainException
Gets CAP_AUTOFEED capability value. If TRUE, the Source will automatically feed the next page from the document feeder after the frame negotiated for capture from each page are acquired. CAP_FEEDERENABLED must be TRUE to use this capability. Set the capability to TRUE to enable the Source's automatic feed process, or FALSE to disable it. After the completion of each transfer, check hasMoreImages. CAP_FEEDERLOADED indicates whether the Source's feeder is loaded. (The automatic feed process continues whenever this capability is TRUE.)

Throws:
TwainException

setAutoFeed

public void setAutoFeed(boolean value)
                 throws TwainException
Sets CAP_AUTOFEED capability value.
See getAutoFeed() for description.

Throws:
TwainException

getAutomaticCapture

public int getAutomaticCapture()
                        throws TwainException
Gets CAP_AUTOMATICCAPTURE capability value. The number of images to automatically capture. This does not refer to the number of images to be sent to the Application, use CAP_XFERCOUNT for that.

Throws:
TwainException

setAutomaticCapture

public void setAutomaticCapture(int value)
                         throws TwainException
Sets CAP_AUTOMATICCAPTURE capability value.
See getAutomaticCapture() for description.

Throws:
TwainException

getAutoScan

public boolean getAutoScan()
                    throws TwainException
Gets CAP_AUTOSCAN capability value. This capability is intended to boost the performance of a Source. The fundamental assumption behind AutoScan is that the device is able to capture the number of images indicated by the value of CAP_XFERCOUNT without waiting for the Application to request the image transfers. This is only possible if the device has internal buffers capable of caching the images it captures. The default behavior is undefined, because some high volume devices are incapable of anything but CAP_AUTOSCAN being equal to TRUE. However, if a Source supports FALSE, it should use it as the mandatory default, since this best describes the behavior of pre-1.8 TWAIN Applications. The application should check the hasMoreImages, and continue to scan until it becomes 0. When AutoScan is set to TRUE, the Application should not rely on just the paper sensors (for example, CAP_FEEDERLOADED) to determine if there are images to be transferred. The latency between the Source and the Application makes it very likely that at the time the sensor reports FALSE, there may be more than one image waiting for the transfer inside of the device's buffers.

Throws:
TwainException

setAutoScan

public void setAutoScan(boolean value)
                 throws TwainException
Sets CAP_AUTOSCAN capability value.
See getAutoScan() for description.

Throws:
TwainException

getBatteryMinutes

public int getBatteryMinutes()
                      throws TwainException
Gets CAP_BATTERYMINUTES capability value. The minutes of battery power remaining to the device.

Throws:
TwainException

getBatteryPercentage

public int getBatteryPercentage()
                         throws TwainException
Gets CAP_BATTERYPERCENTAGE capability value. When used with get method, return the percentage of battery power level on camera. If -1 is returned, it indicates that the battery is not present. Use this capability with get method to indicate to the user about the battery power status. It is recommended to use CAP_POWERSUPPLY to identify the power source first.

Throws:
TwainException

getCameraPreviewUI

public boolean getCameraPreviewUI()
                           throws TwainException
Gets CAP_CAMERAPREVIEWUI capability value. This capability queries the Source for UI support for preview mode. If TRUE, the Source supports preview UI. Use this capability to query the preview UI support by the Source. However, the application can choose to use the Source's UI or not even if the Source supports it.

Throws:
TwainException

getCaption

public java.lang.String getCaption()
                            throws TwainException
Gets CAP_CAPTION capability value. A general note about the acquired image.

Throws:
TwainException

setCaption

public void setCaption(java.lang.String value)
                throws TwainException
Sets CAP_CAPTION capability value.
See getCaption() for description.

Throws:
TwainException

getClearBuffers

public int getClearBuffers()
                    throws TwainException
Gets CAP_CLEARBUFFERS capability value. get method reports the presence of data in the scanner's buffers. set method with a value of TWCB_CLEAR immediately clears the buffers.

Throws:
TwainException

setClearBuffers

public void setClearBuffers(int value)
                     throws TwainException
Sets CAP_CLEARBUFFERS capability value.
See getClearBuffers() for description.

Throws:
TwainException

getCustomDSData

public boolean getCustomDSData()
                        throws TwainException
Gets CAP_CUSTOMDSDATA capability value. Allows the application to query the data source to see if it supports the new operation triplets.

Throws:
TwainException

getDeviceOnLine

public boolean getDeviceOnLine()
                        throws TwainException
Gets CAP_DEVICEONLINE capability value. If TRUE, the physical hardware (e.g., scanner, digital camera, image database, etc.) that represents the image source is attached, powered on, and communicating. This capability can be issued at any time to determine the availability of the image source hardware.

Throws:
TwainException

getDeviceTimeDate

public java.lang.String getDeviceTimeDate()
                                   throws TwainException
Gets CAP_DEVICETIMEDATE capability value. The date and time of the device's clock. Managed in the form "YYYY/MM/DD HH:mm:SS:sss" where YYYY is the year, MM is the numerical month, DD is the numerical day, HH is the hour, mm is the minute, SS is the second, and sss is the millisecond.

Throws:
TwainException

setDeviceTimeDate

public void setDeviceTimeDate(java.lang.String value)
                       throws TwainException
Sets CAP_DEVICETIMEDATE capability value.
See getDeviceTimeDate() for description.

Throws:
TwainException

getDuplex

public int getDuplex()
              throws TwainException
Gets CAP_DUPLEX capability value. This indicates whether the scanner supports duplex. Application can use get method to find out whether the scanner supports duplex.

Throws:
TwainException

getDuplexEnabled

public boolean getDuplexEnabled()
                         throws TwainException
Gets CAP_DUPLEXENABLED capability value. The user can set the duplex option to be TRUE or FALSE. If TRUE, the scanner scans both sides of a paper; otherwise, the scanner will scan only one side of the image. Application should use get method to determine if the duplex option is enabled or not.

Throws:
TwainException

setDuplexEnabled

public void setDuplexEnabled(boolean value)
                      throws TwainException
Sets CAP_DUPLEXENABLED capability value.
See getDuplexEnabled() for description.

Throws:
TwainException

getEnableDSUIOnly

public boolean getEnableDSUIOnly()
                          throws TwainException
Gets CAP_ENABLEDSUIONLY capability value. Allows an application to query a source to see if it implements the new user interface settings dialog.

Throws:
TwainException

getEndorser

public int getEndorser()
                throws TwainException
Gets CAP_ENDORSER capability value. Allows the application to specify the starting endorser / imprinter number. All other endorser/ imprinter properties should be handled through the data source's user interface. The user can set the starting number for the endorser.

Throws:
TwainException

setEndorser

public void setEndorser(int value)
                 throws TwainException
Sets CAP_ENDORSER capability value.
See getEndorser() for description.

Throws:
TwainException

getFeederAlignment

public int getFeederAlignment()
                       throws TwainException
Gets CAP_FEEDERALIGNMENT capability value. Helps the Application determine any special actions it may need to take when negotiating frames with the Source. TWFA_NONE: The alignment is free-floating. Applications should assume that the origin for frames is on the left. TWFA_LEFT: The alignment is to the left. TWFA_CENTER: The alignment is centered. This means that the paper will be fed in the middle of the ICAP_PHYSICALWIDTH of the device. If this is set, then the Application should calculate any frames with a left offset of zero. TWFA_RIGHT: The alignment is to the right. The Application can use this to determine if it must center the framing information sent to the Source. With some Sources it might be possible for the Application to select whether the paper is center fed or not.

Throws:
TwainException

setFeederAlignment

public void setFeederAlignment(int value)
                        throws TwainException
Sets CAP_FEEDERALIGNMENT capability value.
See getFeederAlignment() for description.

Throws:
TwainException

getFeederEnabled

public boolean getFeederEnabled()
                         throws TwainException
Gets CAP_FEEDERENABLED capability value. If TRUE, Source must acquire data from the document feeder acquire area and other feeder capabilities can be used. If FALSE, Source must acquire data from the non-feeder acquire area and no other feeder capabilities can be used. The application should set this capability to TRUE before attempting to use any other feeder capabilities. This sets the current acquire area to the feeder area (it may not be a different physical area on some Sources). The application can set this capability to FALSE to use the Source's non-feeder acquisition area and disallow the further use of feeder capabilities.

Throws:
TwainException

setFeederEnabled

public void setFeederEnabled(boolean value)
                      throws TwainException
Sets CAP_FEEDERENABLED capability value.
See getFeederEnabled() for description.

Throws:
TwainException

getFeederLoaded

public boolean getFeederLoaded()
                        throws TwainException
Gets CAP_FEEDERLOADED capability value. Reflect whether there are documents loaded in the Source's feeder. Used by application to inquire whether there are documents loaded in the Source's feeder. CAP_FEEDERENABLED must equal TRUE to use this capability.

Throws:
TwainException

getFeederOrder

public int getFeederOrder()
                   throws TwainException
Gets CAP_FEEDERORDER capability value. TWFO_FIRSTPAGEFIRST if the feeder starts with the top of the first page. TWFO_LASTPAGEFIRST is the feeder starts with the top of the last page. An Application can use this to determine if it should reorganize the stream of images received from a Source.

Throws:
TwainException

setFeederOrder

public void setFeederOrder(int value)
                    throws TwainException
Sets CAP_FEEDERORDER capability value.
See getFeederOrder() for description.

Throws:
TwainException

getIndicators

public boolean getIndicators()
                      throws TwainException
Gets CAP_INDICATORS capability value. If TRUE, the Source will display a progress indicator during acquisition and transfer, regardless of whether the Source's user interface is active. If FALSE, the progress indicator will be suppressed if the Source's user interface is inactive. The Source will continue to display device-specific instructions and error messages even with the Source user interface and progress indicators turned off. If the application plans to enable the Source with setVisible(FALSE), it can also suppress the Source's progress indicator by using this capability.

Throws:
TwainException

setIndicators

public void setIndicators(boolean value)
                   throws TwainException
Sets CAP_INDICATORS capability value.
See getIndicators() for description.

Throws:
TwainException

getJobControl

public int getJobControl()
                  throws TwainException
Gets CAP_JOBCONTROL capability value. Allows multiple jobs in batch mode. The application can decide how the job can be processed, according to the flags listed below.
TWJC_NONE No job control. TWJC_JSIC Detect and include job separator and continue scanning.
TWJC_JSIS Detect and include job separator and stop scanning.
TWJC_JSXC Detect and exclude job separator and continue scanning.
TWJC_JSXS Detect and exclude job separator and stop scanning.
If application selects options other than none, it should check the endOfJob method.

Throws:
TwainException

getSupportedJobControl

public int[] getSupportedJobControl()
                             throws TwainException
Gets CAP_JOBCONTROL capability supported values.
See getJobControl() for description.

Throws:
TwainException

getDefaultJobControl

public int getDefaultJobControl()
                         throws TwainException
Gets CAP_JOBCONTROL capability default value.
See getJobControl() for description.

Throws:
TwainException

setJobControl

public void setJobControl(int value)
                   throws TwainException
Sets CAP_JOBCONTROL capability value.
See getJobControl() for description.

Throws:
TwainException

getLanguage

public int getLanguage()
                throws TwainException
Gets CAP_LANGUAGE capability value. Allows Application and Source to identify which languages they have in common for the exchange of string data, and to select the language of the internal UI. Note: Since the TWLG_xxxx codes include language and country data, there is no separate capability for selecting the country. In multi-lingual environments, it is the responsibility of the Application to recall the last selected language for a given User.

Throws:
TwainException

getSupportedLanguage

public int[] getSupportedLanguage()
                           throws TwainException
Gets CAP_LANGUAGE capability supported values.
See getLanguage() for description.

Throws:
TwainException

getDefaultLanguage

public int getDefaultLanguage()
                       throws TwainException
Gets CAP_LANGUAGE capability default value.
See getLanguage() for description.

Throws:
TwainException

setLanguage

public void setLanguage(int value)
                 throws TwainException
Sets CAP_LANGUAGE capability value.
See getLanguage() for description.

Throws:
TwainException

getMaxBatchBuffers

public int getMaxBatchBuffers()
                       throws TwainException
Gets CAP_MAXBATCHBUFFERS capability value. Describes the number of pages that the scanner can buffer when CAP_AUTOSCAN is enabled. get method returns the supported values. set method sets the current number pages to be buffered (if the Source allows this to be set).

Throws:
TwainException

getSupportedMaxBatchBuffers

public int[] getSupportedMaxBatchBuffers()
                                  throws TwainException
Gets CAP_MAXBATCHBUFFERS capability supported values.
See getMaxBatchBuffers() for description.

Throws:
TwainException

getDefaultMaxBatchBuffers

public int getDefaultMaxBatchBuffers()
                              throws TwainException
Gets CAP_MAXBATCHBUFFERS capability default value.
See getMaxBatchBuffers() for description.

Throws:
TwainException

setMaxBatchBuffers

public void setMaxBatchBuffers(int value)
                        throws TwainException
Sets CAP_MAXBATCHBUFFERS capability value.
See getMaxBatchBuffers() for description.

Throws:
TwainException

getPaperDetectable

public boolean getPaperDetectable()
                           throws TwainException
Gets CAP_PAPERDETECTABLE capability value. This capability determines whether the device has a paper sensor that can detect documents on the ADF or Flatbed. If the source returns FALSE, the application should not rely on values such as CAP_FEEDERLOADED, and continue as if the paper is loaded.

Throws:
TwainException

getPowerSupply

public int getPowerSupply()
                   throws TwainException
Gets CAP_POWERSUPPLY capability value. get method reports the kinds of power available to the device. MSG_GETCURRENT reports the current power supply in use.

Throws:
TwainException

getSupportedPowerSupply

public int[] getSupportedPowerSupply()
                              throws TwainException
Gets CAP_POWERSUPPLY capability supported values.
See getPowerSupply() for description.

Throws:
TwainException

getDefaultPowerSupply

public int getDefaultPowerSupply()
                          throws TwainException
Gets CAP_POWERSUPPLY capability default value.
See getPowerSupply() for description.

Throws:
TwainException

getPrinter

public int getPrinter()
               throws TwainException
Gets CAP_PRINTER capability value. Get method returns the current list of available printer devices, along with the one currently being used for negotiation. Set method selects the current device for negotiation, and optionally constrains the list.

Throws:
TwainException

getSupportedPrinter

public int[] getSupportedPrinter()
                          throws TwainException
Gets CAP_PRINTER capability supported values.
See getPrinter() for description.

Throws:
TwainException

getDefaultPrinter

public int getDefaultPrinter()
                      throws TwainException
Gets CAP_PRINTER capability default value.
See getPrinter() for description.

Throws:
TwainException

setPrinter

public void setPrinter(int value)
                throws TwainException
Sets CAP_PRINTER capability value.
See getPrinter() for description.

Throws:
TwainException

getPrinterEnabled

public boolean getPrinterEnabled()
                          throws TwainException
Gets CAP_PRINTERENABLED capability value. Turns the current CAP_PRINTER device on or off.

Throws:
TwainException

setPrinterEnabled

public void setPrinterEnabled(boolean value)
                       throws TwainException
Sets CAP_PRINTERENABLED capability value.
See getPrinterEnabled() for description.

Throws:
TwainException

getPrinterIndex

public int getPrinterIndex()
                    throws TwainException
Gets CAP_PRINTERINDEX capability value. The User can set the starting number for the current CAP_PRINTER device.

Throws:
TwainException

setPrinterIndex

public void setPrinterIndex(int value)
                     throws TwainException
Sets CAP_PRINTERINDEX capability value.
See getPrinterIndex() for description.

Throws:
TwainException

getPrinterMode

public int getPrinterMode()
                   throws TwainException
Gets CAP_PRINTERMODE capability value. Specifies the appropriate current CAP_PRINTER device mode. Note: ??TWPM_SINGLESTRING specifies that the printed text will consist of a single string. ??TWPM _MULTISTRING specifies that the printed text will consist of an enumerated list of strings to be printed in order. ??TWPM _COMPOUNDSTRING specifies that the printed string will consist of a compound of a String followed by a value followed by a suffix string. Negotiate this capability to specify the mode of printing to use when the current CAP_PRINTER device is enabled.

Throws:
TwainException

getSupportedPrinterMode

public int[] getSupportedPrinterMode()
                              throws TwainException
Gets CAP_PRINTERMODE capability supported values.
See getPrinterMode() for description.

Throws:
TwainException

getDefaultPrinterMode

public int getDefaultPrinterMode()
                          throws TwainException
Gets CAP_PRINTERMODE capability default value.
See getPrinterMode() for description.

Throws:
TwainException

setPrinterMode

public void setPrinterMode(int value)
                    throws TwainException
Sets CAP_PRINTERMODE capability value.
See getPrinterMode() for description.

Throws:
TwainException

getPrinterString

public java.lang.String getPrinterString()
                                  throws TwainException
Gets CAP_PRINTERSTRING capability value. Specifies the string(s) that are to be used in the string component when the current CAP_PRINTER device is enabled. Negotiate this capability to specify the string or strings to be used for printing (depending on printer mode). Use enumeration to print multiple lines of text, one line per string in the enumerated list. Be sure to check the status codes if attempting multiple lines, since not all devices support this feature.

Throws:
TwainException

setPrinterString

public void setPrinterString(java.lang.String value)
                      throws TwainException
Sets CAP_PRINTERSTRING capability value.
See getPrinterString() for description.

Throws:
TwainException

getPrinterSuffix

public java.lang.String getPrinterSuffix()
                                  throws TwainException
Gets CAP_PRINTERSUFFIX capability value. Specifies the string that shall be used as the current CAP_PRINTER device's suffix. Negotiate this capability to specify the string that is used as the suffix for printing if TWPM_COMPOUNDSTRING is used.

Throws:
TwainException

setPrinterSuffix

public void setPrinterSuffix(java.lang.String value)
                      throws TwainException
Sets CAP_PRINTERSUFFIX capability value.
See getPrinterSuffix() for description.

Throws:
TwainException

getSerialNumber

public java.lang.String getSerialNumber()
                                 throws TwainException
Gets CAP_SERIALNUMBER capability value. A string containing the serial number of the currently selected device in the Source. Multiple devices may all report the same serial number. The value is device specific, Applications should not attempt to parse the information.

Throws:
TwainException

getTimeBeforeFirstCapture

public int getTimeBeforeFirstCapture()
                              throws TwainException
Gets CAP_TIMEBEFOREFIRSTCAPTURE capability value. For automatic capture, this value selects the number of milliseconds before the first picture is to be taken, or the first image is to be scanned.

Throws:
TwainException

setTimeBeforeFirstCapture

public void setTimeBeforeFirstCapture(int value)
                               throws TwainException
Sets CAP_TIMEBEFOREFIRSTCAPTURE capability value.
See getTimeBeforeFirstCapture() for description.

Throws:
TwainException

getTimeBetweenCaptures

public int getTimeBetweenCaptures()
                           throws TwainException
Gets CAP_TIMEBETWEENCAPTURES capability value. For automatic capture, this value selects the milliseconds to wait between pictures taken, or images scanned.

Throws:
TwainException

setTimeBetweenCaptures

public void setTimeBetweenCaptures(int value)
                            throws TwainException
Sets CAP_TIMEBETWEENCAPTURES capability value.
See getTimeBetweenCaptures() for description.

Throws:
TwainException

getTimeDate

public java.lang.String getTimeDate()
                             throws TwainException
Gets CAP_TIMEDATE capability value. The date and time the image was acquired. Note: CAP_TIMEDATE does not return the exact time the image was acquired; rather, it returns the closest available approximation of the time the physical phenomena represented by the image was recorded. If the application needs the exact time of acquisition, the application should generate that value itself during the image acquisition procedure. Stored in the form "YYYY/MM/DD HH:mm:SS.sss" where YYYY is the year, MM is the numerical month, DD is the numerical day, HH is the hour, mm is the minute, SS is the second, and sss is the millisecond.

Throws:
TwainException

getThumbnailsEnabled

public boolean getThumbnailsEnabled()
                             throws TwainException
Gets CAP_THUMBNAILSENABLED capability value. Allows an application to request the delivery of thumbnail representations for the set of images that are to be delivered. Setting CAP_THUMBNAILSENABLED to TRUE turns on thumbnail mode. Images transferred thereafter will be sent at thumbnail size (exact thumbnail size is determined by the Data Source). Setting this capability to FALSE turns thumbnail mode off and returns full size images. A successful set of this capability to TRUE will cause the Source to deliver image thumbnails during normal data transfer operations. This mode remains in effect until this capability is set back to FALSE.

Throws:
TwainException

setThumbnailsEnabled

public void setThumbnailsEnabled(boolean value)
                          throws TwainException
Sets CAP_THUMBNAILSENABLED capability value.
See getThumbnailsEnabled() for description.

Throws:
TwainException

getUIControllable

public boolean getUIControllable()
                          throws TwainException
Gets CAP_UICONTROLLABLE capability value. If TRUE, indicates that this Source supports acquisition with the UI disabled; i.e., setVisible can be set to FALSE. If FALSE, indicates that this Source can only support acquisition with the UI enabled.

Throws:
TwainException

getTransferCount

public int getTransferCount()
                     throws TwainException
Gets CAP_XFERCOUNT capability value. The application is willing to accept this number of images. Set this capability to the number of images you are willing to transfer per session. Common values are: 1 Application wishes to transfer only one image this session -1 Application is willing to transfer multiple images

Throws:
TwainException

setTransferCount

public void setTransferCount(int value)
                      throws TwainException
Sets CAP_XFERCOUNT capability value.
See getTransferCount() for description.

Throws:
TwainException

getAutomaticBorderDetection

public boolean getAutomaticBorderDetection()
                                    throws TwainException
Gets ICAP_AUTOMATICBORDERDETECTION capability value. Turns automatic border detection on and off. Negotiate this capability to determine the state of the AutoBorder detection. ICAP_UNDEFINEDIMAGESIZE must be enabled for this feature to work.

Throws:
TwainException

setAutomaticBorderDetection

public void setAutomaticBorderDetection(boolean value)
                                 throws TwainException
Sets ICAP_AUTOMATICBORDERDETECTION capability value.
See getAutomaticBorderDetection() for description.

Throws:
TwainException

getAutoBright

public boolean getAutoBright()
                      throws TwainException
Gets ICAP_AUTOBRIGHT capability value. TRUE enables and FALSE disables the Source's Auto-brightness function (if any).

Throws:
TwainException

setAutoBright

public void setAutoBright(boolean value)
                   throws TwainException
Sets ICAP_AUTOBRIGHT capability value.
See getAutoBright() for description.

Throws:
TwainException

getAutomaticDeskew

public boolean getAutomaticDeskew()
                           throws TwainException
Gets ICAP_AUTOMATICDESKEW capability value. Turns automatic deskew correction on and off.

Throws:
TwainException

setAutomaticDeskew

public void setAutomaticDeskew(boolean value)
                        throws TwainException
Sets ICAP_AUTOMATICDESKEW capability value.
See getAutomaticDeskew() for description.

Throws:
TwainException

getAutomaticRotate

public boolean getAutomaticRotate()
                           throws TwainException
Gets ICAP_AUTOMATICROTATE capability value. When TRUE this capability depends on intelligent features within the Source to automatically rotate the image to the correct position. If this capability is set to TRUE, then it must be assumed that no other correction is required (deskew, rotation, etc...); the Source is guaranteeing that it will deliver images in the correct orientation.

Throws:
TwainException

setAutomaticRotate

public void setAutomaticRotate(boolean value)
                        throws TwainException
Sets ICAP_AUTOMATICROTATE capability value.
See getAutomaticRotate() for description.

Throws:
TwainException

getBarCodeDetectionEnabled

public boolean getBarCodeDetectionEnabled()
                                   throws TwainException
Gets ICAP_BARCODEDETECTIONENABLED capability value. Turns bar code detection on and off.

Throws:
TwainException

setBarCodeDetectionEnabled

public void setBarCodeDetectionEnabled(boolean value)
                                throws TwainException
Sets ICAP_BARCODEDETECTIONENABLED capability value.
See getBarCodeDetectionEnabled() for description.

Throws:
TwainException

getBarCodeMaxRetries

public int getBarCodeMaxRetries()
                         throws TwainException
Gets ICAP_BARCODEMAXRETRIES capability value. Restricts the number of times a search will be retried if none are found on each page. Refine this capability to limit the number of times the bar code search algorithm is retried on a page that contains no bar codes.

Throws:
TwainException

getSupportedBarCodeMaxRetries

public int[] getSupportedBarCodeMaxRetries()
                                    throws TwainException
Gets ICAP_BARCODEMAXRETRIES capability supported values.
See getBarCodeMaxRetries() for description.

Throws:
TwainException

getDefaultBarCodeMaxRetries

public int getDefaultBarCodeMaxRetries()
                                throws TwainException
Gets ICAP_BARCODEMAXRETRIES capability default value.
See getBarCodeMaxRetries() for description.

Throws:
TwainException

setBarCodeMaxRetries

public void setBarCodeMaxRetries(int value)
                          throws TwainException
Sets ICAP_BARCODEMAXRETRIES capability value.
See getBarCodeMaxRetries() for description.

Throws:
TwainException

getBarCodeMaxSearchPriorities

public int getBarCodeMaxSearchPriorities()
                                  throws TwainException
Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability value. The maximum number of supported search priorities. Query this value to determine how many bar code detection priorities can be set. Set this value to limit the number of priorities to speed the detection process.

Throws:
TwainException

getSupportedBarCodeMaxSearchPriorities

public int[] getSupportedBarCodeMaxSearchPriorities()
                                             throws TwainException
Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability supported values.
See getBarCodeMaxSearchPriorities() for description.

Throws:
TwainException

getDefaultBarCodeMaxSearchPriorities

public int getDefaultBarCodeMaxSearchPriorities()
                                         throws TwainException
Gets ICAP_BARCODEMAXSEARCHPRIORITIES capability default value.
See getBarCodeMaxSearchPriorities() for description.

Throws:
TwainException

setBarCodeMaxSearchPriorities

public void setBarCodeMaxSearchPriorities(int value)
                                   throws TwainException
Sets ICAP_BARCODEMAXSEARCHPRIORITIES capability value.
See getBarCodeMaxSearchPriorities() for description.

Throws:
TwainException

getBarCodeSearchMode

public int getBarCodeSearchMode()
                         throws TwainException
Gets ICAP_BARCODESEARCHMODE capability value. Restricts bar code searching to certain orientations, or prioritizes one orientation over the other. Negotiate this capability if the orientation of bar codes is already known to the application. Refinement of this capability can speed the bar code search.

Throws:
TwainException

getSupportedBarCodeSearchMode

public int[] getSupportedBarCodeSearchMode()
                                    throws TwainException
Gets ICAP_BARCODESEARCHMODE capability supported values.
See getBarCodeSearchMode() for description.

Throws:
TwainException

getDefaultBarCodeSearchMode

public int getDefaultBarCodeSearchMode()
                                throws TwainException
Gets ICAP_BARCODESEARCHMODE capability default value.
See getBarCodeSearchMode() for description.

Throws:
TwainException

setBarCodeSearchMode

public void setBarCodeSearchMode(int value)
                          throws TwainException
Sets ICAP_BARCODESEARCHMODE capability value.
See getBarCodeSearchMode() for description.

Throws:
TwainException

getBarCodeTimeout

public int getBarCodeTimeout()
                      throws TwainException
Gets ICAP_BARCODETIMEOUT capability value. Restricts the total time spent on searching for a bar code on each page. Refine this value to tune the length of time the search algorithm is allowed to execute before giving up.

Throws:
TwainException

getSupportedBarCodeTimeout

public int[] getSupportedBarCodeTimeout()
                                 throws TwainException
Gets ICAP_BARCODETIMEOUT capability supported values.
See getBarCodeTimeout() for description.

Throws:
TwainException

getDefaultBarCodeTimeout

public int getDefaultBarCodeTimeout()
                             throws TwainException
Gets ICAP_BARCODETIMEOUT capability default value.
See getBarCodeTimeout() for description.

Throws:
TwainException

setBarCodeTimeout

public void setBarCodeTimeout(int value)
                       throws TwainException
Sets ICAP_BARCODETIMEOUT capability value.
See getBarCodeTimeout() for description.

Throws:
TwainException

getBitDepth

public int getBitDepth()
                throws TwainException
Gets ICAP_BITDEPTH capability value. Specifies the pixel bit depths for the Current value of ICAP_PIXELTYPE. For example, when using ICAP_PIXELTYPE = TWPT_GRAY, this capability specifies whether this is 8-bit gray or 4-bit gray. This depth applies to all the data channels (for instance, the R, G, and B channels will all have this same bit depth for RGB data). The application should loop through all the ICAP_PIXELTYPEs it is interested in and negotiate the ICAP_BITDEPTH(s) for each.

Specified by:
getBitDepth in interface MorenaSource
Throws:
TwainException

getSupportedBitDepth

public int[] getSupportedBitDepth()
                           throws TwainException
Gets ICAP_BITDEPTH capability supported values.
See getBitDepth() for description.

Throws:
TwainException

getDefaultBitDepth

public int getDefaultBitDepth()
                       throws TwainException
Gets ICAP_BITDEPTH capability default value.
See getBitDepth() for description.

Throws:
TwainException

setBitDepth

public void setBitDepth(int value)
                 throws TwainException
Sets ICAP_BITDEPTH capability value.
See getBitDepth() for description.

Specified by:
setBitDepth in interface MorenaSource
Throws:
TwainException

getBitDepthReduction

public int getBitDepthReduction()
                         throws TwainException
Gets ICAP_BITDEPTHREDUCTION capability value. Specifies the Reduction Method the Source should use to reduce the bit depth of the data. Most commonly used with ICAP_PIXELTYPE = TWPT_BW to reduce gray data to black and white. Set the capability to the reduction method to be used in future acquisitions Also select the Halftone or Threshold to be used.

Throws:
TwainException

getSupportedBitDepthReduction

public int[] getSupportedBitDepthReduction()
                                    throws TwainException
Gets ICAP_BITDEPTHREDUCTION capability supported values.
See getBitDepthReduction() for description.

Throws:
TwainException

getDefaultBitDepthReduction

public int getDefaultBitDepthReduction()
                                throws TwainException
Gets ICAP_BITDEPTHREDUCTION capability default value.
See getBitDepthReduction() for description.

Throws:
TwainException

setBitDepthReduction

public void setBitDepthReduction(int value)
                          throws TwainException
Sets ICAP_BITDEPTHREDUCTION capability value.
See getBitDepthReduction() for description.

Throws:
TwainException

getBitOrder

public int getBitOrder()
                throws TwainException
Gets ICAP_BITORDER capability value. Specifies how the bytes in an image are filled by the Source. TWBO_MSBFIRST indicates that the leftmost bit in the byte (usually bit 7) is the byte's Most Significant Bit.

Throws:
TwainException

getSupportedBitOrder

public int[] getSupportedBitOrder()
                           throws TwainException
Gets ICAP_BITORDER capability supported values.
See getBitOrder() for description.

Throws:
TwainException

getDefaultBitOrder

public int getDefaultBitOrder()
                       throws TwainException
Gets ICAP_BITORDER capability default value.
See getBitOrder() for description.

Throws:
TwainException

setBitOrder

public void setBitOrder(int value)
                 throws TwainException
Sets ICAP_BITORDER capability value.
See getBitOrder() for description.

Throws:
TwainException

getBitOrderCodes

public int getBitOrderCodes()
                     throws TwainException
Gets ICAP_BITORDERCODES capability value. Used for CCITT data compression only. Indicates the bit order representation of the stored compressed codes.

Throws:
TwainException

getSupportedBitOrderCodes

public int[] getSupportedBitOrderCodes()
                                throws TwainException
Gets ICAP_BITORDERCODES capability supported values.
See getBitOrderCodes() for description.

Throws:
TwainException

getDefaultBitOrderCodes

public int getDefaultBitOrderCodes()
                            throws TwainException
Gets ICAP_BITORDERCODES capability default value.
See getBitOrderCodes() for description.

Throws:
TwainException

setBitOrderCodes

public void setBitOrderCodes(int value)
                      throws TwainException
Sets ICAP_BITORDERCODES capability value.
See getBitOrderCodes() for description.

Throws:
TwainException

getBrightness

public double getBrightness()
                     throws TwainException
Gets ICAP_BRIGHTNESS capability value. The brightness values available within the Source. The application can use this capability to inquire, set, or restrict the values for BRIGHTNESS used in the Source.

Specified by:
getBrightness in interface MorenaSource
Throws:
TwainException

getSupportedBrightness

public double[] getSupportedBrightness()
                                throws TwainException
Gets ICAP_BRIGHTNESS capability supported values.
See getBrightness() for description.

Throws:
TwainException

getDefaultBrightness

public double getDefaultBrightness()
                            throws TwainException
Gets ICAP_BRIGHTNESS capability default value.
See getBrightness() for description.

Throws:
TwainException

setBrightness

public void setBrightness(double value)
                   throws TwainException
Sets ICAP_BRIGHTNESS capability value.
See getBrightness() for description.

Specified by:
setBrightness in interface MorenaSource
Throws:
TwainException

getCCITTKFactor

public int getCCITTKFactor()
                    throws TwainException
Gets ICAP_CCITTKFACTOR capability value. Used for CCITT Group 3 2-dimensional compression. The 'K' factor indicates how often the new compression baseline should be re-established. A value of 2 or 4 is common in facsimile communication. A value of zero in this field will indicate an infinite K factor•À?the baseline is only calculated at the beginning of the transfer.

Throws:
TwainException

setCCITTKFactor

public void setCCITTKFactor(int value)
                     throws TwainException
Sets ICAP_CCITTKFACTOR capability value.
See getCCITTKFactor() for description.

Throws:
TwainException

getCompression

public int getCompression()
                   throws TwainException
Gets ICAP_COMPRESSION capability value. Allows the application and Source to identify which compression schemes they have in common for File transfers. Note for File transfers: Since only certain file formats support compression, this capability must be negotiated after setting the desired file format with ICAP_IMAGEFILEFORMAT.
TWCP_NONE All Sources must support this.
TWCP_PACKBITS Macintosh PackBits format, (can be used with TIFF or PICT)
TWCP_GROUP31D, TWCP_GROUP31DEOL, TWCP_GROUP32D, TWCP_GROUP4 Are all from the CCITT specification (now ITU), intended for document images (can be used with TIFF).
TWCP_JPEG Intended for the compression of color photographs (can be used with TIFF, JFIF or SPIFF).
TWCP_LZW A compression licensed by UNISYS (can be used with TIFF).
TWCP_JBIG Intended for bitonal and grayscale document images (can be used with TIFF or SPIFF).
TWCP_PNG This compression can only be used if ICAP_IMAGEFILEFORMAT is set to TWFF_PNG.
TWCP_RLE4, TWCP_RLE8, TWCP_BITFIELDS These compressions can only be used if ICAP_IMAGEFILEFORMAT is set to TWFF_BMP.
Applications must not assume that a Source can provide compressed File transfers, because many cannot. The application should use set method to specify the compression type for future transfers.

Throws:
TwainException

getSupportedCompression

public int[] getSupportedCompression()
                              throws TwainException
Gets ICAP_COMPRESSION capability supported values.
See getCompression() for description.

Throws:
TwainException

getDefaultCompression

public int getDefaultCompression()
                          throws TwainException
Gets ICAP_COMPRESSION capability default value.
See getCompression() for description.

Throws:
TwainException

setCompression

public void setCompression(int value)
                    throws TwainException
Sets ICAP_COMPRESSION capability value.
See getCompression() for description.

Throws:
TwainException

getContrast

public double getContrast()
                   throws TwainException
Gets ICAP_CONTRAST capability value. The contrast values available within the Source. The application can use this capability to inquire, set or restrict the values for CONTRAST used in the Source.

Specified by:
getContrast in interface MorenaSource
Throws:
TwainException

getSupportedContrast

public double[] getSupportedContrast()
                              throws TwainException
Gets ICAP_CONTRAST capability supported values.
See getContrast() for description.

Throws:
TwainException

getDefaultContrast

public double getDefaultContrast()
                          throws TwainException
Gets ICAP_CONTRAST capability default value.
See getContrast() for description.

Throws:
TwainException

setContrast

public void setContrast(double value)
                 throws TwainException
Sets ICAP_CONTRAST capability value.
See getContrast() for description.

Specified by:
setContrast in interface MorenaSource
Throws:
TwainException

getExposureTime

public double getExposureTime()
                       throws TwainException
Gets ICAP_EXPOSURETIME capability value. Specifies the exposure time used to capture the image, in seconds.

Throws:
TwainException

getSupportedExposureTime

public double[] getSupportedExposureTime()
                                  throws TwainException
Gets ICAP_EXPOSURETIME capability supported values.
See getExposureTime() for description.

Throws:
TwainException

getDefaultExposureTime

public double getDefaultExposureTime()
                              throws TwainException
Gets ICAP_EXPOSURETIME capability default value.
See getExposureTime() for description.

Throws:
TwainException

setExposureTime

public void setExposureTime(double value)
                     throws TwainException
Sets ICAP_EXPOSURETIME capability value.
See getExposureTime() for description.

Throws:
TwainException

getExtImageInfo

public boolean getExtImageInfo()
                        throws TwainException
Gets ICAP_EXTIMAGEINFO capability value. If not supported, return TWRC_FAILURE/ TWCC_CAPUNSUPPORTED.

Throws:
TwainException

setExtImageInfo

public void setExtImageInfo(boolean value)
                     throws TwainException
Sets ICAP_EXTIMAGEINFO capability value.
See getExtImageInfo() for description.

Throws:
TwainException

getFilter

public int getFilter()
              throws TwainException
Gets ICAP_FILTER capability value. Describes the color characteristic of the subtractive filter applied to the image data. Multiple filters may be applied to a single acquisition.

Throws:
TwainException

setFilter

public void setFilter(int value)
               throws TwainException
Sets ICAP_FILTER capability value.
See getFilter() for description.

Throws:
TwainException

getFlashUsed

public int getFlashUsed()
                 throws TwainException
Gets ICAP_FLASHUSED2 capability value. For devices that support flash. Set method selects the flash to be used (if any). Get method reports the current setting. This capability replaces ICAP_FLASHUSED, which is only able to negotiate the flash being on or off. Note that an image with flash may have a different color composition than an image without flash.

Throws:
TwainException

getSupportedFlashUsed

public int[] getSupportedFlashUsed()
                            throws TwainException
Gets ICAP_FLASHUSED2 capability supported values.
See getFlashUsed() for description.

Throws:
TwainException

getDefaultFlashUsed

public int getDefaultFlashUsed()
                        throws TwainException
Gets ICAP_FLASHUSED2 capability default value.
See getFlashUsed() for description.

Throws:
TwainException

setFlashUsed

public void setFlashUsed(int value)
                  throws TwainException
Sets ICAP_FLASHUSED2 capability value.
See getFlashUsed() for description.

Throws:
TwainException

getFlipRotation

public int getFlipRotation()
                    throws TwainException
Gets ICAP_FLIPROTATION capability value. Flip rotation is used to properly orient images that flip orientation every other image. TWFR_BOOK The images to be scanned are viewed in book form, flipping each page from left to right or right to left. A B B A Direction of scan TWFR_FANFOLD The images to be scanned are viewed in fanfold paper style, flipping each page up or down.
B
A A
B
Direction of scan
On duplex paper, the As are all located on the top, and the Bs are all located on the bottom. If ICAP_FLIPROTATION is set to TWFR_BOOK, and fanfold paper is scanned, then every B image will be upside down. Setting the capability to TWFR_FANFOLD instructs the Source to rotate the B images 180 degrees around the x-axis.
Because this capability is described to act upon every other image, it will work correctly in simplex mode, assuming that every other simplex image is flipped in the manner described above.

Throws:
TwainException

setFlipRotation

public void setFlipRotation(int value)
                     throws TwainException
Sets ICAP_FLIPROTATION capability value.
See getFlipRotation() for description.

Throws:
TwainException

getGamma

public double getGamma()
                throws TwainException
Gets ICAP_GAMMA capability value. Gamma correction value for the image data. Do not use with TW_CIECOLOR, TW_GRAYRESPONSE, or TW_RGBRESPONSE data.

Throws:
TwainException

setGamma

public void setGamma(double value)
              throws TwainException
Sets ICAP_GAMMA capability value.
See getGamma() for description.

Throws:
TwainException

getHalftones

public java.lang.String getHalftones()
                              throws TwainException
Gets ICAP_HALFTONES capability value. A list of names of the halftone patterns available within the Source. The application may not rename any halftone pattern. The application should also set ICAP_BITDEPTHREDUCTION to use this capability.

Throws:
TwainException

setHalftones

public void setHalftones(java.lang.String value)
                  throws TwainException
Sets ICAP_HALFTONES capability value.
See getHalftones() for description.

Throws:
TwainException

getHighlight

public double getHighlight()
                    throws TwainException
Gets ICAP_HIGHLIGHT capability value. Specifies which value in an image should be interpreted as the lightest "highlight." All values "lighter" than this value will be clipped to this value. Whether lighter values are smaller or larger can be determined by examining the Current value of ICAP_PIXELFLAVOR.

Throws:
TwainException

getSupportedHighlight

public double[] getSupportedHighlight()
                               throws TwainException
Gets ICAP_HIGHLIGHT capability supported values.
See getHighlight() for description.

Throws:
TwainException

getDefaultHighlight

public double getDefaultHighlight()
                           throws TwainException
Gets ICAP_HIGHLIGHT capability default value.
See getHighlight() for description.

Throws:
TwainException

setHighlight

public void setHighlight(double value)
                  throws TwainException
Sets ICAP_HIGHLIGHT capability value.
See getHighlight() for description.

Throws:
TwainException

getImageDataSet

public int getImageDataSet()
                    throws TwainException
Gets ICAP_IMAGEDATASET capability value.

Throws:
TwainException

setImageDataSet

public void setImageDataSet(int value)
                     throws TwainException
Sets ICAP_IMAGEDATASET capability value.
See getImageDataSet() for description.

Throws:
TwainException

getImageFileFormat

public int getImageFileFormat()
                       throws TwainException
Gets ICAP_IMAGEFILEFORMAT capability value. Informs the application which file formats the Source can generate (get). Tells the Source which file formats the application can handle (set).
TWFF_TIFF Used for document imaging
TWFF_PICT Native Macintosh format
TWFF_BMP Native Microsoft format
TWFF_XBM Used for document imaging
TWFF_JFIF Wrapper for JPEG images
TWFF_FPX FlashPix, used with digital cameras
TWFF_TIFFMULTI Multi-page TIFF files
TWFF_PNG An image format standard intended for use on the web, replaces GIF
TWFF_SPIFF A standard from JPEG, intended to replace JFIF, also supports JBIG
TWFF_EXIF File format for use with digital cameras.
Use this ICAP to determine which formats are available for file transfers, and set the context for other capability negotiations such as ICAP_COMPRESSION.

Throws:
TwainException

getSupportedImageFileFormat

public int[] getSupportedImageFileFormat()
                                  throws TwainException
Gets ICAP_IMAGEFILEFORMAT capability supported values.
See getImageFileFormat() for description.

Throws:
TwainException

getDefaultImageFileFormat

public int getDefaultImageFileFormat()
                              throws TwainException
Gets ICAP_IMAGEFILEFORMAT capability default value.
See getImageFileFormat() for description.

Throws:
TwainException

setImageFileFormat

public void setImageFileFormat(int value)
                        throws TwainException
Sets ICAP_IMAGEFILEFORMAT capability value.
See getImageFileFormat() for description.

Throws:
TwainException

getImageFilter

public int getImageFilter()
                   throws TwainException
Gets ICAP_IMAGEFILTER capability value. For devices that support image enhancement filtering. This capability selects the algorithm used to improve the quality of the image. TWIF_LOWPASS is good for halftone images. TWIF_BANDPASS is good for improving text. TWIF_HIGHPASS is good for improving fine lines.

Throws:
TwainException

getSupportedImageFilter

public int[] getSupportedImageFilter()
                              throws TwainException
Gets ICAP_IMAGEFILTER capability supported values.
See getImageFilter() for description.

Throws:
TwainException

getDefaultImageFilter

public int getDefaultImageFilter()
                          throws TwainException
Gets ICAP_IMAGEFILTER capability default value.
See getImageFilter() for description.

Throws:
TwainException

setImageFilter

public void setImageFilter(int value)
                    throws TwainException
Sets ICAP_IMAGEFILTER capability value.
See getImageFilter() for description.

Throws:
TwainException

getJPEGPixelType

public int getJPEGPixelType()
                     throws TwainException
Gets ICAP_JPEGPIXELTYPE capability value.

Throws:
TwainException

getSupportedJPEGPixelType

public int[] getSupportedJPEGPixelType()
                                throws TwainException
Gets ICAP_JPEGPIXELTYPE capability supported values.
See getJPEGPixelType() for description.

Throws:
TwainException

getDefaultJPEGPixelType

public int getDefaultJPEGPixelType()
                            throws TwainException
Gets ICAP_JPEGPIXELTYPE capability default value.
See getJPEGPixelType() for description.

Throws:
TwainException

setJPEGPixelType

public void setJPEGPixelType(int value)
                      throws TwainException
Sets ICAP_JPEGPIXELTYPE capability value.
See getJPEGPixelType() for description.

Throws:
TwainException

getJPEGQuality

public int getJPEGQuality()
                   throws TwainException
Gets ICAP_JPEGQUALITY capability value. Use this capability as a shortcut to select JPEG quantization tables that tradeoff quality versus compressed image size. Used in concert with DAT_JPEGCOMPRESSION it is possible for an Application to obtain the tables that are appropriate for varying percentages of quality within a given Source. TWJQ_UNKNOWN is a read-only value (get or getCurrent), the Application cannot set the Source to this value. This value is reported if the Application uses DAT_JPEGCOMPRESSION to select the quantization tables, and the Source is unable to resolve those tables to a percentage value. The next three TWJQ_ values are intended as markers into the quality range, and are only applicable with set method. get, getCurrent and getDefault only return values in the range 0 - 100. If an Application wishes to map a TWJQ_ value to a corresponding value in the range 0 - 100, then it must issue a get after a set with one of the three TWJQ_ values. No assumption is made about the meaning of the range 0 - 99, it may be derived from the JPEG standard or it may be optimized for the Source's device. 100, though, implies a lossless form of compression. Applications are not encouraged to use this value since it results in poor compression, as well as a format that is not currently widely supported in the industry.
TWJQ_UNKNOWN - read-only; must be the setting for this capability if the user sets the JPEG compression tables using DAT_JPEGCOMPRESSION, and the Source is not able to map the selected tables to a specific percentage of quality.
TWJQ_LOW - write-only; implies low quality; the images are at the maximum compression recommended by the Source.
TWJQ_MEDIUM - write-only; implies medium quality; the images are at the balance point between good compression and good images. This is an arbitrary setting on the part of the Source writer that is expected to best represent their device. This is the value that Applications are most encouraged to use.
TWJQ_HIGH - write-only; implies high quality; the images display the maximum quality that produces any kind of meaningful compression. Note that images at this setting are still considered to be lossy.

Throws:
TwainException

getSupportedJPEGQuality

public int[] getSupportedJPEGQuality()
                              throws TwainException
Gets ICAP_JPEGQUALITY capability supported values.
See getJPEGQuality() for description.

Throws:
TwainException

getDefaultJPEGQuality

public int getDefaultJPEGQuality()
                          throws TwainException
Gets ICAP_JPEGQUALITY capability default value.
See getJPEGQuality() for description.

Throws:
TwainException

setJPEGQuality

public void setJPEGQuality(int value)
                    throws TwainException
Sets ICAP_JPEGQUALITY capability value.
See getJPEGQuality() for description.

Throws:
TwainException

getLampState

public boolean getLampState()
                     throws TwainException
Gets ICAP_LAMPSTATE capability value. TRUE means the lamp is currently, or should be set to ON. Sources may not support set operations.

Throws:
TwainException

getSupportedLampState

public boolean[] getSupportedLampState()
                                throws TwainException
Gets ICAP_LAMPSTATE capability supported values.
See getLampState() for description.

Throws:
TwainException

getDefaultLampState

public boolean getDefaultLampState()
                            throws TwainException
Gets ICAP_LAMPSTATE capability default value.
See getLampState() for description.

Throws:
TwainException

setLampState

public void setLampState(boolean value)
                  throws TwainException
Sets ICAP_LAMPSTATE capability value.
See getLampState() for description.

Throws:
TwainException

getLightPath

public int getLightPath()
                 throws TwainException
Gets ICAP_LIGHTPATH capability value. Describes whether the image was captured transmissively or reflectively.

Throws:
TwainException

getSupportedLightPath

public int[] getSupportedLightPath()
                            throws TwainException
Gets ICAP_LIGHTPATH capability supported values.
See getLightPath() for description.

Throws:
TwainException

getDefaultLightPath

public int getDefaultLightPath()
                        throws TwainException
Gets ICAP_LIGHTPATH capability default value.
See getLightPath() for description.

Throws:
TwainException

setLightPath

public void setLightPath(int value)
                  throws TwainException
Sets ICAP_LIGHTPATH capability value.
See getLightPath() for description.

Throws:
TwainException

getLightSource

public int getLightSource()
                   throws TwainException
Gets ICAP_LIGHTSOURCE capability value. Describes the general color characteristic of the light source used to acquire the image.

Throws:
TwainException

getSupportedLightSource

public int[] getSupportedLightSource()
                              throws TwainException
Gets ICAP_LIGHTSOURCE capability supported values.
See getLightSource() for description.

Throws:
TwainException

getDefaultLightSource

public int getDefaultLightSource()
                          throws TwainException
Gets ICAP_LIGHTSOURCE capability default value.
See getLightSource() for description.

Throws:
TwainException

setLightSource

public void setLightSource(int value)
                    throws TwainException
Sets ICAP_LIGHTSOURCE capability value.
See getLightSource() for description.

Throws:
TwainException

getMinimumHeight

public double getMinimumHeight()
                        throws TwainException
Gets ICAP_MINIMUMHEIGHT capability value. Allows the source to define the minimum height (Y-axis) that the source can acquire.

Throws:
TwainException

getMinimumWidth

public double getMinimumWidth()
                       throws TwainException
Gets ICAP_MINIMUMWIDTH capability value. Allows the source to define theminimum width (X-axis) that the source can acquire.

Throws:
TwainException

getNoiseFilter

public int getNoiseFilter()
                   throws TwainException
Gets ICAP_NOISEFILTER capability value. For devices that support noise filtering. This capability selects the algorithm used to remove noise.

Throws:
TwainException

getSupportedNoiseFilter

public int[] getSupportedNoiseFilter()
                              throws TwainException
Gets ICAP_NOISEFILTER capability supported values.
See getNoiseFilter() for description.

Throws:
TwainException

getDefaultNoiseFilter

public int getDefaultNoiseFilter()
                          throws TwainException
Gets ICAP_NOISEFILTER capability default value.
See getNoiseFilter() for description.

Throws:
TwainException

setNoiseFilter

public void setNoiseFilter(int value)
                    throws TwainException
Sets ICAP_NOISEFILTER capability value.
See getNoiseFilter() for description.

Throws:
TwainException

getOrientation

public int getOrientation()
                   throws TwainException
Gets ICAP_ORIENTATION capability value. Defines which edge of the "paper" the image's "top" is aligned with. This information is used to adjust the frames to match the scanning orientation of the paper. For instance, if an ICAP_SUPPORTEDSIZE of TWSS_ISOA4 has been negotiated, and ICAP_ORIENTATION is set to TWOR_LANDSCAPE, then the Source must rotate the frame it downloads to the scanner to reflect the orientation of the paper. Please note that setting ICAP_ORIENTATION does not affect the values reported by ICAP_FRAMES; it just causes the Source to use them in a different way.
The upper-left of the image is defined as the location where both the primary and secondary scans originate. (The X axis is the primary scan direction and the Y axis is the secondary scan direction.) For a flatbed scanner, the light bar moves in the secondary scan direction. For a handheld scanner, the scanner is drug in the secondary scan direction. For a digital camera, the secondary direction is the vertical axis when the viewed image is considered upright. If one pivots the image about its center, then orienting the image in TWOR_LANDSCAPE has the effect of rotating the original image 90 degrees to the "left." TWOR_PORTRAIT mode does not rotate the image. The image may be oriented along any of the four axes located 90 degrees from the unrotated image. Note that: TWOR_ROT0 == TWOR_PORTRAIT and TWOR_ROT270 == TWOR_LANDSCAPE.

Throws:
TwainException

getSupportedOrientation

public int[] getSupportedOrientation()
                              throws TwainException
Gets ICAP_ORIENTATION capability supported values.
See getOrientation() for description.

Throws:
TwainException

getDefaultOrientation

public int getDefaultOrientation()
                          throws TwainException
Gets ICAP_ORIENTATION capability default value.
See getOrientation() for description.

Throws:
TwainException

setOrientation

public void setOrientation(int value)
                    throws TwainException
Sets ICAP_ORIENTATION capability value.
See getOrientation() for description.

Throws:
TwainException

getOverscan

public int getOverscan()
                throws TwainException
Gets ICAP_OVERSCAN capability value. Overscan is used to scan outside of the boundaries described by ICAP_FRAMES, and is used to help acquire image data that may be lost because of skewing. Consider the following: Frame Paper Overscan This is primarily of use for transport scanners which rely on edge detection to begin scanning. If overscan is supported, then the device is capable of scanning in the inter-document gap to get the skewed image information. Use this capability, if available, to help software processing images for deskew and border removal.

Throws:
TwainException

getSupportedOverscan

public int[] getSupportedOverscan()
                           throws TwainException
Gets ICAP_OVERSCAN capability supported values.
See getOverscan() for description.

Throws:
TwainException

getDefaultOverscan

public int getDefaultOverscan()
                       throws TwainException
Gets ICAP_OVERSCAN capability default value.
See getOverscan() for description.

Throws:
TwainException

setOverscan

public void setOverscan(int value)
                 throws TwainException
Sets ICAP_OVERSCAN capability value.
See getOverscan() for description.

Throws:
TwainException

getPatchCodeDetectionEnabled

public boolean getPatchCodeDetectionEnabled()
                                     throws TwainException
Gets ICAP_PATCHCODEDETECTIONENABLED capability value. Turns patch code detection on and off.

Throws:
TwainException

setPatchCodeDetectionEnabled

public void setPatchCodeDetectionEnabled(boolean value)
                                  throws TwainException
Sets ICAP_PATCHCODEDETECTIONENABLED capability value.
See getPatchCodeDetectionEnabled() for description.

Throws:
TwainException

getPatchCodeMaxRetries

public int getPatchCodeMaxRetries()
                           throws TwainException
Gets ICAP_PATCHCODEMAXRETRIES capability value. Restricts the number of times a search will be retried if none are found on each page. Refine this capability to limit the number of times the patch code search algorithm is retried on a page that contains no patch codes.

Throws:
TwainException

getSupportedPatchCodeMaxRetries

public int[] getSupportedPatchCodeMaxRetries()
                                      throws TwainException
Gets ICAP_PATCHCODEMAXRETRIES capability supported values.
See getPatchCodeMaxRetries() for description.

Throws:
TwainException

getDefaultPatchCodeMaxRetries

public int getDefaultPatchCodeMaxRetries()
                                  throws TwainException
Gets ICAP_PATCHCODEMAXRETRIES capability default value.
See getPatchCodeMaxRetries() for description.

Throws:
TwainException

setPatchCodeMaxRetries

public void setPatchCodeMaxRetries(int value)
                            throws TwainException
Sets ICAP_PATCHCODEMAXRETRIES capability value.
See getPatchCodeMaxRetries() for description.

Throws:
TwainException

getPatchCodeMaxSearchPriorities

public int getPatchCodeMaxSearchPriorities()
                                    throws TwainException
Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability value. The maximum number of supported search priorities. Query this value to determine how many patch code detection priorities can be set.

Throws:
TwainException

getSupportedPatchCodeMaxSearchPriorities

public int[] getSupportedPatchCodeMaxSearchPriorities()
                                               throws TwainException
Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability supported values.
See getPatchCodeMaxSearchPriorities() for description.

Throws:
TwainException

getDefaultPatchCodeMaxSearchPriorities

public int getDefaultPatchCodeMaxSearchPriorities()
                                           throws TwainException
Gets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability default value.
See getPatchCodeMaxSearchPriorities() for description.

Throws:
TwainException

setPatchCodeMaxSearchPriorities

public void setPatchCodeMaxSearchPriorities(int value)
                                     throws TwainException
Sets ICAP_PATCHCODEMAXSEARCHPRIORITIES capability value.
See getPatchCodeMaxSearchPriorities() for description.

Throws:
TwainException

getPatchCodeSearchMode

public int getPatchCodeSearchMode()
                           throws TwainException
Gets ICAP_PATCHCODESEARCHMODE capability value. Restricts patch code searching to certain orientations, or prioritizes one orientation over the other. Negotiate this capability if the orientation of patch codes is already known to the application. Refinement of this capability can speed the patch code search.

Throws:
TwainException

getSupportedPatchCodeSearchMode

public int[] getSupportedPatchCodeSearchMode()
                                      throws TwainException
Gets ICAP_PATCHCODESEARCHMODE capability supported values.
See getPatchCodeSearchMode() for description.

Throws:
TwainException

getDefaultPatchCodeSearchMode

public int getDefaultPatchCodeSearchMode()
                                  throws TwainException
Gets ICAP_PATCHCODESEARCHMODE capability default value.
See getPatchCodeSearchMode() for description.

Throws:
TwainException

setPatchCodeSearchMode

public void setPatchCodeSearchMode(int value)
                            throws TwainException
Sets ICAP_PATCHCODESEARCHMODE capability value.
See getPatchCodeSearchMode() for description.

Throws:
TwainException

getPatchCodeTimeout

public int getPatchCodeTimeout()
                        throws TwainException
Gets ICAP_PATCHCODETIMEOUT capability value. Restricts the total time spent on searching for a patch code on each page. Refine this value to tune the length of time the search algorithm is allowed to execute before giving up.

Throws:
TwainException

getSupportedPatchCodeTimeout

public int[] getSupportedPatchCodeTimeout()
                                   throws TwainException
Gets ICAP_PATCHCODETIMEOUT capability supported values.
See getPatchCodeTimeout() for description.

Throws:
TwainException

getDefaultPatchCodeTimeout

public int getDefaultPatchCodeTimeout()
                               throws TwainException
Gets ICAP_PATCHCODETIMEOUT capability default value.
See getPatchCodeTimeout() for description.

Throws:
TwainException

setPatchCodeTimeout

public void setPatchCodeTimeout(int value)
                         throws TwainException
Sets ICAP_PATCHCODETIMEOUT capability value.
See getPatchCodeTimeout() for description.

Throws:
TwainException

getPhysicalHeight

public double getPhysicalHeight()
                         throws TwainException
Gets ICAP_PHYSICALHEIGHT capability value. The maximum physical height (Y-axis) the Source can acquire (measured in units of ICAP_UNITS).

Throws:
TwainException

getPhysicalWidth

public double getPhysicalWidth()
                        throws TwainException
Gets ICAP_PHYSICALWIDTH capability value. The maximum physical width (X-axis) the Source can acquire (measured in units of ICAP_UNITS).

Throws:
TwainException

getPixelFlavor

public int getPixelFlavor()
                   throws TwainException
Gets ICAP_PIXELFLAVOR capability value. Sense of the pixel whose numeric value is zero (minimum data value). For example, consider a black and white image: If ICAP_PIXELTYPE is TWPT_BW then If ICAP_PIXELFLAVOR is TWPF_CHOCOLATE then Black = 0 Else if ICAP_PIXELFLAVOR is TWPF_VANILLA then White = 0 Sources may prefer a different value depending on ICAP_PIXELTYPE. Set ICAP_PIXELTYPE and do a getDefault to determine the Source's preferences.

Throws:
TwainException

getSupportedPixelFlavor

public int[] getSupportedPixelFlavor()
                              throws TwainException
Gets ICAP_PIXELFLAVOR capability supported values.
See getPixelFlavor() for description.

Throws:
TwainException

getDefaultPixelFlavor

public int getDefaultPixelFlavor()
                          throws TwainException
Gets ICAP_PIXELFLAVOR capability default value.
See getPixelFlavor() for description.

Throws:
TwainException

setPixelFlavor

public void setPixelFlavor(int value)
                    throws TwainException
Sets ICAP_PIXELFLAVOR capability value.
See getPixelFlavor() for description.

Throws:
TwainException

getPixelFlavorCodes

public int getPixelFlavorCodes()
                        throws TwainException
Gets ICAP_PIXELFLAVORCODES capability value. Used only for CCITT data compression. Specifies whether the compressed codes' pixel "sense" will be inverted from the Current value of ICAP_PIXELFLAVOR prior to transfer.

Throws:
TwainException

getSupportedPixelFlavorCodes

public int[] getSupportedPixelFlavorCodes()
                                   throws TwainException
Gets ICAP_PIXELFLAVORCODES capability supported values.
See getPixelFlavorCodes() for description.

Throws:
TwainException

getDefaultPixelFlavorCodes

public int getDefaultPixelFlavorCodes()
                               throws TwainException
Gets ICAP_PIXELFLAVORCODES capability default value.
See getPixelFlavorCodes() for description.

Throws:
TwainException

setPixelFlavorCodes

public void setPixelFlavorCodes(int value)
                         throws TwainException
Sets ICAP_PIXELFLAVORCODES capability value.
See getPixelFlavorCodes() for description.

Throws:
TwainException

getPixelType

public int getPixelType()
                 throws TwainException
Gets ICAP_PIXELTYPE capability value. The type of pixel data that a Source is capable of acquiring (for example, black and white, gray, RGB, etc.). Get method returns a list of all pixel types available from the Source. Set method specifies the only pixel type the application can accept. If the application plans to transfer data through any mechanism other than Native and cannot handle all possible ICAP_PIXELTYPEs, it must support negotiation of this ICAP.

Throws:
TwainException

getSupportedPixelType

public int[] getSupportedPixelType()
                            throws TwainException
Gets ICAP_PIXELTYPE capability supported values.
See getPixelType() for description.

Throws:
TwainException

getDefaultPixelType

public int getDefaultPixelType()
                        throws TwainException
Gets ICAP_PIXELTYPE capability default value.
See getPixelType() for description.

Throws:
TwainException

setPixelType

public void setPixelType(int value)
                  throws TwainException
Sets ICAP_PIXELTYPE capability value.
See getPixelType() for description.

Throws:
TwainException

getPlanarChunky

public int getPlanarChunky()
                    throws TwainException
Gets ICAP_PLANARCHUNKY capability value. Allows the application and Source to identify which color data formats are available. There are two options, "planar" and "chunky." For example, planar RGB data is transferred with the entire red plane of data first, followed by the entire green plane, followed by the entire blue plane (typical for three-pass scanners). "Chunky" mode repetitively interlaces a pixel from each plane until all the data is transferred (R-G-B-R-G-B...) (typical for one-pass scanners).

Throws:
TwainException

getSupportedPlanarChunky

public int[] getSupportedPlanarChunky()
                               throws TwainException
Gets ICAP_PLANARCHUNKY capability supported values.
See getPlanarChunky() for description.

Throws:
TwainException

getDefaultPlanarChunky

public int getDefaultPlanarChunky()
                           throws TwainException
Gets ICAP_PLANARCHUNKY capability default value.
See getPlanarChunky() for description.

Throws:
TwainException

setPlanarChunky

public void setPlanarChunky(int value)
                     throws TwainException
Sets ICAP_PLANARCHUNKY capability value.
See getPlanarChunky() for description.

Throws:
TwainException

getRotation

public double getRotation()
                   throws TwainException
Gets ICAP_ROTATION capability value. How the Source can/should rotate the scanned image data prior to transfer. This doesn't use ICAP_UNITS. It is always measured in degrees. Any applied value is additive with any rotation specified in ICAP_ORIENTATION.

Throws:
TwainException

getSupportedRotation

public double[] getSupportedRotation()
                              throws TwainException
Gets ICAP_ROTATION capability supported values.
See getRotation() for description.

Throws:
TwainException

getDefaultRotation

public double getDefaultRotation()
                          throws TwainException
Gets ICAP_ROTATION capability default value.
See getRotation() for description.

Throws:
TwainException

setRotation

public void setRotation(double value)
                 throws TwainException
Sets ICAP_ROTATION capability value.
See getRotation() for description.

Throws:
TwainException

getShadow

public double getShadow()
                 throws TwainException
Gets ICAP_SHADOW capability value. Specifies which value in an image should be interpreted as the darkest "shadow." All values "darker" than this value will be clipped to this value. Whether darker values are smaller or larger can be determined by examining the Current value of ICAP_PIXELFLAVOR.

Throws:
TwainException

getSupportedShadow

public double[] getSupportedShadow()
                            throws TwainException
Gets ICAP_SHADOW capability supported values.
See getShadow() for description.

Throws:
TwainException

getDefaultShadow

public double getDefaultShadow()
                        throws TwainException
Gets ICAP_SHADOW capability default value.
See getShadow() for description.

Throws:
TwainException

setShadow

public void setShadow(double value)
               throws TwainException
Sets ICAP_SHADOW capability value.
See getShadow() for description.

Throws:
TwainException

getSupportedPatchCodeTypes

public int getSupportedPatchCodeTypes()
                               throws TwainException
Gets ICAP_SUPPORTEDPATCHCODETYPES capability value. A list of patch code types that may be detected by the current Data Source. Query this capability to determine if the Data Source can detect patch codes that are appropriate to the Application.

Throws:
TwainException

getSupportedSizes

public int getSupportedSizes()
                      throws TwainException
Gets ICAP_SUPPORTEDSIZES capability value. For devices that support fixed frame sizes. Defined sizes match typical page sizes. This specifies the size(s) the Source can/should use to acquire image data. (*) Constant should not be used in Sources or Applications using TWAIN 1.8 or higher. For instance, use TWSS_A4 instead of TWSS_A4LETTER (note that the values are the same, the reason for the new constants is to improve naming clarification and consistency). Note: TWSS_B has been removed from the specification.

Throws:
TwainException

getSupportedSupportedSizes

public int[] getSupportedSupportedSizes()
                                 throws TwainException
Gets ICAP_SUPPORTEDSIZES capability supported values.
See getSupportedSizes() for description.

Throws:
TwainException

getDefaultSupportedSizes

public int getDefaultSupportedSizes()
                             throws TwainException
Gets ICAP_SUPPORTEDSIZES capability default value.
See getSupportedSizes() for description.

Throws:
TwainException

setSupportedSizes

public void setSupportedSizes(int value)
                       throws TwainException
Sets ICAP_SUPPORTEDSIZES capability value.
See getSupportedSizes() for description.

Throws:
TwainException

getThreshold

public double getThreshold()
                    throws TwainException
Gets ICAP_THRESHOLD capability value. Specifies the dividing line between black and white. This is the value the Source will use to threshold, if needed, when ICAP_PIXELTYPE = TWPT_BW. The value is normalized so there are no units of measure associated with this ICAP. Application will typically set ICAP_BITDEPTHREDUCTION to TWBR_THRESHOLD to use this capability. Source should fit available values linearly into the defined range such that the lowest available value equals 0 and the highest equals 255.

Throws:
TwainException

getSupportedThreshold

public double[] getSupportedThreshold()
                               throws TwainException
Gets ICAP_THRESHOLD capability supported values.
See getThreshold() for description.

Throws:
TwainException

getDefaultThreshold

public double getDefaultThreshold()
                           throws TwainException
Gets ICAP_THRESHOLD capability default value.
See getThreshold() for description.

Throws:
TwainException

setThreshold

public void setThreshold(double value)
                  throws TwainException
Sets ICAP_THRESHOLD capability value.
See getThreshold() for description.

Throws:
TwainException

getTimeFill

public int getTimeFill()
                throws TwainException
Gets ICAP_TIMEFILL capability value. Used only with CCITT data compression. Specifies the minimum number of words of compressed codes (compressed data) to be transmitted per line.

Throws:
TwainException

setTimeFill

public void setTimeFill(int value)
                 throws TwainException
Sets ICAP_TIMEFILL capability value.
See getTimeFill() for description.

Throws:
TwainException

getUndefinedImageSize

public boolean getUndefinedImageSize()
                              throws TwainException
Gets ICAP_UNDEFINEDIMAGESIZE capability value. Used by the application to notify the Source that the application accepts -1 as the image width or -length in the TW_IMAGEINFO structure.

Throws:
TwainException

setUndefinedImageSize

public void setUndefinedImageSize(boolean value)
                           throws TwainException
Sets ICAP_UNDEFINEDIMAGESIZE capability value.
See getUndefinedImageSize() for description.

Throws:
TwainException

getUnits

public int getUnits()
             throws TwainException
Gets ICAP_UNITS capability value. Unless a quantity is dimensionless or uses a specified unit of measure, ICAP_UNITS determines the unit of measure for all quantities. Applications should be able to handle TWUN_PIXELS if they want to support data transfers from "dimensionless" devices such as digital cameras.

Throws:
TwainException

getSupportedUnits

public int[] getSupportedUnits()
                        throws TwainException
Gets ICAP_UNITS capability supported values.
See getUnits() for description.

Throws:
TwainException

getDefaultUnits

public int getDefaultUnits()
                    throws TwainException
Gets ICAP_UNITS capability default value.
See getUnits() for description.

Throws:
TwainException

setUnits

public void setUnits(int value)
              throws TwainException
Sets ICAP_UNITS capability value.
See getUnits() for description.

Throws:
TwainException

getTransferMech

public int getTransferMech()
                    throws TwainException
Gets ICAP_XFERMECH capability value. Allows the application and Source to identify which transfer mechanisms they have in common.

Throws:
TwainException

getSupportedTransferMech

public int[] getSupportedTransferMech()
                               throws TwainException
Gets ICAP_XFERMECH capability supported values.
See getTransferMech() for description.

Throws:
TwainException

getDefaultTransferMech

public int getDefaultTransferMech()
                           throws TwainException
Gets ICAP_XFERMECH capability default value.
See getTransferMech() for description.

Throws:
TwainException

setTransferMech

public void setTransferMech(int value)
                     throws TwainException
Sets ICAP_XFERMECH capability value.
See getTransferMech() for description.

Throws:
TwainException

getXNativeResolution

public double getXNativeResolution()
                            throws TwainException
Gets ICAP_XNATIVERESOLUTION capability value. The native optical resolution along the X-axis of the device being controlled by the Source. Most devices will respond with a single value. This is NOT a list of all resolutions that can be generated by the device. Rather, this is the resolution of the device's optics. Measured in units of pixels per unit as defined by ICAP_UNITS (pixels per TWUN_PIXELS yields dimensionless data).

Throws:
TwainException

getSupportedXNativeResolution

public double[] getSupportedXNativeResolution()
                                       throws TwainException
Gets ICAP_XNATIVERESOLUTION capability supported values.
See getXNativeResolution() for description.

Throws:
TwainException

getDefaultXNativeResolution

public double getDefaultXNativeResolution()
                                   throws TwainException
Gets ICAP_XNATIVERESOLUTION capability default value.
See getXNativeResolution() for description.

Throws:
TwainException

getXResolution

public double getXResolution()
                      throws TwainException
Gets ICAP_XRESOLUTION capability value. All the X-axis resolutions the Source can provide. Measured in units of pixels per unit as defined by ICAP_UNITS (pixels per TWUN_PIXELS yields dimensionless data). That is, when the units are TWUN_PIXELS, both ICAP_XRESOLUTION and ICAP_YRESOLUTION shall report 1 pixel/pixel. Some data sources like to report the actual number of pixels that the device reports, but that response is more appropriate in ICAP_PHYSICALHEIGHT and ICAP_PHYSICALWIDTH. Setting this value will restrict the various resolutions that will be available to the user during acquisition. Applications will want to ensure that the values set for this ICAP match those set for ICAP_YRESOLUTION.

Throws:
TwainException

getSupportedXResolution

public double[] getSupportedXResolution()
                                 throws TwainException
Gets ICAP_XRESOLUTION capability supported values.
See getXResolution() for description.

Throws:
TwainException

getDefaultXResolution

public double getDefaultXResolution()
                             throws TwainException
Gets ICAP_XRESOLUTION capability default value.
See getXResolution() for description.

Throws:
TwainException

setXResolution

public void setXResolution(double value)
                    throws TwainException
Sets ICAP_XRESOLUTION capability value.
See getXResolution() for description.

Throws:
TwainException

getXScaling

public double getXScaling()
                   throws TwainException
Gets ICAP_XSCALING capability value. All the X-axis scaling values available. A value of '1.0' is equivalent to 100% scaling. Do not use values less than or equal to zero. Applications will want to ensure that the values set for this ICAP match those set for ICAP_YSCALING. There are no units inherent with this data as it is normalized to 1.0 being "unscaled."

Throws:
TwainException

getSupportedXScaling

public double[] getSupportedXScaling()
                              throws TwainException
Gets ICAP_XSCALING capability supported values.
See getXScaling() for description.

Throws:
TwainException

getDefaultXScaling

public double getDefaultXScaling()
                          throws TwainException
Gets ICAP_XSCALING capability default value.
See getXScaling() for description.

Throws:
TwainException

setXScaling

public void setXScaling(double value)
                 throws TwainException
Sets ICAP_XSCALING capability value.
See getXScaling() for description.

Throws:
TwainException

getYNativeResolution

public double getYNativeResolution()
                            throws TwainException
Gets ICAP_YNATIVERESOLUTION capability value. The native optical resolution along the Y-axis of the device being controlled by the Source. Measured in units of pixels per unit as defined by ICAP_UNITS (pixels per TWUN_PIXELS yields dimensionless data). Most devices will respond with a single value. This is NOT a list of all resolutions that can be generated by the device. Rather, this is the resolution of the device's optics

Throws:
TwainException

getSupportedYNativeResolution

public double[] getSupportedYNativeResolution()
                                       throws TwainException
Gets ICAP_YNATIVERESOLUTION capability supported values.
See getYNativeResolution() for description.

Throws:
TwainException

getDefaultYNativeResolution

public double getDefaultYNativeResolution()
                                   throws TwainException
Gets ICAP_YNATIVERESOLUTION capability default value.
See getYNativeResolution() for description.

Throws:
TwainException

getYResolution

public double getYResolution()
                      throws TwainException
Gets ICAP_YRESOLUTION capability value. All the Y-axis resolutions the Source can provide. Measured in units of pixels per unit as defined by ICAP_UNITS (pixels per TWUN_PIXELS yields dimensionless data). That is, when the units are TWUN_PIXELS, both ICAP_XRESOLUTION and ICAP_YRESOLUTION shall report 1 pixel/pixel. Some data sources like to report the actual number of pixels that the device reports, but that response is more appropriate in ICAP_PHYSICALHEIGHT and ICAP_PHYSICALWIDTH. Setting this value will restrict the various resolutions that will be available to the user during acquisition. Applications will want to ensure that the values set for this ICAP match those set for ICAP_XRESOLUTION.

Throws:
TwainException

getSupportedYResolution

public double[] getSupportedYResolution()
                                 throws TwainException
Gets ICAP_YRESOLUTION capability supported values.
See getYResolution() for description.

Throws:
TwainException

getDefaultYResolution

public double getDefaultYResolution()
                             throws TwainException
Gets ICAP_YRESOLUTION capability default value.
See getYResolution() for description.

Throws:
TwainException

setYResolution

public void setYResolution(double value)
                    throws TwainException
Sets ICAP_YRESOLUTION capability value.
See getYResolution() for description.

Throws:
TwainException

getYScaling

public double getYScaling()
                   throws TwainException
Gets ICAP_YSCALING capability value. All the Y-axis scaling values available. A value of '1.0' is equivalent to 100% scaling. Do not use values less than or equal to zero. There are no units inherent with this data as it is normalized to 1.0 being "unscaled." Applications will want to ensure that the values set for this ICAP match those set for ICAP_XSCALING.

Throws:
TwainException

getSupportedYScaling

public double[] getSupportedYScaling()
                              throws TwainException
Gets ICAP_YSCALING capability supported values.
See getYScaling() for description.

Throws:
TwainException

getDefaultYScaling

public double getDefaultYScaling()
                          throws TwainException
Gets ICAP_YSCALING capability default value.
See getYScaling() for description.

Throws:
TwainException

setYScaling

public void setYScaling(double value)
                 throws TwainException
Sets ICAP_YSCALING capability value.
See getYScaling() for description.

Throws:
TwainException

getZoomFactor

public int getZoomFactor()
                  throws TwainException
Gets ICAP_ZOOMFACTOR capability value. When used with get method, return all camera supported lens zooming range. Use this capability with set method to select one of the lens zooming value that the Source supports.

Throws:
TwainException

getSupportedZoomFactor

public int[] getSupportedZoomFactor()
                             throws TwainException
Gets ICAP_ZOOMFACTOR capability supported values.
See getZoomFactor() for description.

Throws:
TwainException

getDefaultZoomFactor

public int getDefaultZoomFactor()
                         throws TwainException
Gets ICAP_ZOOMFACTOR capability default value.
See getZoomFactor() for description.

Throws:
TwainException

setZoomFactor

public void setZoomFactor(int value)
                   throws TwainException
Sets ICAP_ZOOMFACTOR capability value.
See getZoomFactor() for description.

Throws:
TwainException

addConsumer

public void addConsumer(java.awt.image.ImageConsumer consumer)
This method is used to register an ImageConsumer with the ImageProducer for access to the image data during a later reconstruction of the Image. The ImageProducer may, at its discretion, start delivering the image data to the consumer using the ImageConsumer interface immediately, or when the next available image reconstruction is triggered by a call to the startProduction method.

Specified by:
addConsumer in interface java.awt.image.ImageProducer
See Also:
startProduction(java.awt.image.ImageConsumer)

isConsumer

public boolean isConsumer(java.awt.image.ImageConsumer consumer)
This method determines if a given ImageConsumer object is currently registered with this ImageProducer as one of its consumers.

Specified by:
isConsumer in interface java.awt.image.ImageProducer

removeConsumer

public void removeConsumer(java.awt.image.ImageConsumer consumer)
This method removes the given ImageConsumer object from the list of consumers currently registered to receive image data. It is not considered an error to remove a consumer that is not currently registered. The ImageProducer should stop sending data to this consumer as soon as is feasible.

Specified by:
removeConsumer in interface java.awt.image.ImageProducer

startProduction

public void startProduction(java.awt.image.ImageConsumer consumer)
This method both registers the given ImageConsumer object as a consumer and starts an immediate reconstruction of the image data which will then be delivered to this consumer and any other consumer which may have already been registered with the producer. This method differs from the addConsumer method in that a reproduction of the image data should be triggered as soon as possible.

Specified by:
startProduction in interface java.awt.image.ImageProducer
See Also:
addConsumer(java.awt.image.ImageConsumer)

requestTopDownLeftRightResend

public void requestTopDownLeftRightResend(java.awt.image.ImageConsumer consumer)
Not used.

Specified by:
requestTopDownLeftRightResend in interface java.awt.image.ImageProducer