Package com.iizix.barcode
Class BarcodeReader
java.lang.Object
com.iizix.barcode.BarcodeReader
Barcode reader implementation that will scan an image for a barcode.
- Author:
- Christopher Mindus
- Constructor SummaryConstructors
- Method SummaryModifier and TypeMethodDescription- static BarcodeData- readBarcode- (BufferedImage image) Scans a BufferedImage and attempts to detect a single barcode.- static BarcodeData- readBarcode- (File file) Reads a file and attempts to detect a single barcode.- static BarcodeDataReads an input stream as an image of PNG or JPEG type and attempts to detect a single barcode.- static BarcodeData- readBarcode- (String fileName) Reads a file and attempts to detect a single barcode.
- Constructor Details- BarcodeReaderpublic BarcodeReader()
 
- Method Details- readBarcodeReads a file and attempts to detect a single barcode.- Parameters:
- fileName- The file name to read.
- Returns:
- The barcode data.
- Throws:
- IOException- For file I/O errors.
- NotFoundException- If a barcode is not found.
 
- readBarcodeReads a file and attempts to detect a single barcode.- Parameters:
- file- The file to read.
- Returns:
- The barcode data.
- Throws:
- IOException- For file I/O errors.
- NotFoundException- If a barcode is not found.
 
- readBarcodeReads an input stream as an image of PNG or JPEG type and attempts to detect a single barcode.- Parameters:
- in- The input stream to read.- Note: it is up to the caller to close the input stream. 
- Returns:
- The barcode data.
- Throws:
- IOException- For I/O errors.
- NotFoundException- If a barcode is not found.
 
- readBarcodeScans a BufferedImage and attempts to detect a single barcode.- Parameters:
- image- The image.
- Returns:
- The barcode data.
- Throws:
- NotFoundException- If a barcode is not found.